Commit
•
1b0b961
1
Parent(s):
cc0f83e
fix
Browse files- Dockerfile +4 -3
Dockerfile
CHANGED
@@ -32,10 +32,11 @@ RUN rm /etc/nginx/conf.d/default.conf
|
|
32 |
COPY --from=build /app/dist /usr/share/nginx/html
|
33 |
|
34 |
# Replace the default nginx.conf with our configuration
|
35 |
-
COPY nginx.conf /etc/nginx/conf
|
36 |
|
37 |
-
#
|
38 |
-
RUN
|
|
|
39 |
|
40 |
# Ensure the /var/run/nginx.pid file has correct permissions
|
41 |
RUN touch /var/run/nginx.pid && chown user:user /var/run/nginx.pid
|
|
|
32 |
COPY --from=build /app/dist /usr/share/nginx/html
|
33 |
|
34 |
# Replace the default nginx.conf with our configuration
|
35 |
+
COPY nginx.conf /etc/nginx/nginx.conf
|
36 |
|
37 |
+
# Create the necessary directories and set the correct permissions
|
38 |
+
RUN mkdir -p /var/cache/nginx/client_temp /var/cache/nginx/proxy_temp /var/cache/nginx/fastcgi_temp /var/cache/nginx/uwsgi_temp /var/cache/nginx/scgi_temp && \
|
39 |
+
chown -R user:user /usr/share/nginx/html /etc/nginx /var/cache/nginx /var/run /var/log/nginx
|
40 |
|
41 |
# Ensure the /var/run/nginx.pid file has correct permissions
|
42 |
RUN touch /var/run/nginx.pid && chown user:user /var/run/nginx.pid
|