Skip to content

Commit

Permalink
chore: add nginx conf file
Browse files Browse the repository at this point in the history
  • Loading branch information
MattMod authored Jul 1, 2022
2 parents bdfe26c + 5fc2dda commit 73765f8
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 0 deletions.
2 changes: 2 additions & 0 deletions fe-piattaforma/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,8 @@ RUN apk --update add nginx

RUN rm -rf /usr/share/nginx/html/*

COPY fe-piattaforma.nginx.conf /etc/nginx/conf.d/

COPY build /usr/share/nginx/html

EXPOSE 80
Expand Down
28 changes: 28 additions & 0 deletions fe-piattaforma/fe-piattaforma.nginx.conf
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
server {
listen 80;
server_name localhost;

#access_log /var/log/nginx/host.access.log main;

location / {
root /usr/share/nginx/html;
index index.html index.htm;
try_files $uri.html $uri $uri/ /index.html;
}

#error_page 404 /404.html;

# redirect server error pages to the static page /50x.html
#
error_page 500 502 503 504 /50x.html;
location = /50x.html {
root /usr/share/nginx/html;
}

# deny access to .htaccess files, if Apache's document root
# concurs with nginx's one
#
#location ~ /\.ht {
# deny all;
#}
}

0 comments on commit 73765f8

Please sign in to comment.