mirror of
https://github.com/R0m1k3/noteflow.git
synced 2026-10-23 15:18:16 +02:00
[dyad] wrote 3 file(s)
This commit is contained in:
1 parent
a83d87855f
commit
20edfef8bb
3 files changed
+19
-19
No files matched your search
+4
-5
@@ -9,12 +9,11 @@ RUN npm install
|
|||||||
# Copy app source
|
# Copy app source
|
||||||
COPY . .
|
COPY . .
|
||||||
|
|
||||||
# Create necessary directories with correct permissions
|
# Create directories and set permissions
|
||||||
RUN mkdir -p /app/data /app/public/uploads && \
|
RUN mkdir -p /app/data /app/public/uploads && \
|
||||||
chown -R node:node /app/data /app/public/uploads
|
chown -R node:node /app && \
|
||||||
|
chmod -R 755 /app && \
|
||||||
# Switch to non-root user
|
chmod -R 777 /app/data /app/public/uploads
|
||||||
USER node
|
|
||||||
|
|
||||||
# Expose port
|
# Expose port
|
||||||
EXPOSE 2222
|
EXPOSE 2222
|
||||||
|
|||||||
+4
-14
@@ -13,23 +13,13 @@ services:
|
|||||||
- NODE_ENV=production
|
- NODE_ENV=production
|
||||||
- JWT_SECRET=changeme_in_production
|
- JWT_SECRET=changeme_in_production
|
||||||
- PORT=2222
|
- PORT=2222
|
||||||
|
- UID=1000
|
||||||
|
- GID=1000
|
||||||
|
user: "1000:1000" # Utiliser l'utilisateur node
|
||||||
restart: unless-stopped
|
restart: unless-stopped
|
||||||
networks:
|
networks:
|
||||||
- nginx_default
|
- nginx_default
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
nginx_default:
|
nginx_default:
|
||||||
external: true
|
external: true
|
||||||
|
|
||||||
# Nginx configuration example:
|
|
||||||
# location /notes/ {
|
|
||||||
# proxy_pass http://notes-todo-app:2222/;
|
|
||||||
# proxy_http_version 1.1;
|
|
||||||
# proxy_set_header Upgrade $http_upgrade;
|
|
||||||
# proxy_set_header Connection 'upgrade';
|
|
||||||
# proxy_set_header Host $host;
|
|
||||||
# proxy_set_header X-Real-IP $remote_addr;
|
|
||||||
# proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
|
||||||
# proxy_cache_bypass $http_upgrade;
|
|
||||||
# client_max_body_size 10M;
|
|
||||||
# }
|
|
||||||
Reference in new issue
Block a user