fix(Docker): allow PORT environment variable

Taken from #1670
Fix #1450 and #224
This commit is contained in:
ShareVB committed 2026-01-02 23:54:17 +01:00
1 parent aebb3f2052
commit be14d3a62b
2 files changed
+7 -4

No files matched your search

+5 -2
View File
@@ -22,6 +22,9 @@ ENV VITE_VERCEL_ENV production
ARG BASE_URL
ENV BASE_URL=${BASE_URL}
COPY --from=build-stage /app/dist /usr/share/nginx/html
COPY nginx.conf /etc/nginx/conf.d/default.conf
EXPOSE 8080
COPY nginx.conf /etc/nginx/templates/default.conf.template
ENV PORT=8080
EXPOSE $PORT
CMD ["nginx", "-g", "daemon off;"]
+2 -2
View File
@@ -1,6 +1,6 @@
server {
listen 8080;
listen [::]:8080;
listen ${PORT};
listen [::]:${PORT};
server_name _;
root /usr/share/nginx/html;
index index.html;