Fix nginx for other routes

This commit is contained in:
benthecarman
2023-12-12 13:21:37 -06:00
committed by benthecarman
parent 954be2eaea
commit efd17e53be
2 changed files with 12 additions and 0 deletions

View File

@@ -38,6 +38,9 @@ FROM nginx:alpine
# Copy the static assets from the builder stage to the Nginx default static serve directory
COPY --from=builder /app/dist/public /usr/share/nginx/html
# Copy the custom Nginx configuration file into the container
COPY default.conf /etc/nginx/conf.d/default.conf
# Expose the default Nginx port
EXPOSE 80

9
default.conf Normal file
View File

@@ -0,0 +1,9 @@
server {
listen 80;
location / {
root /usr/share/nginx/html;
index index.html index.htm;
try_files $uri $uri/ /index.html;
}
}