[dyad] wrote 2 file(s)

This commit is contained in:
Michael committed 2025-11-06 13:53:22 +01:00
1 parent 81f60c7965
commit 8122880caa
2 files changed
+10 -9

No files matched your search

+4 -9
View File
@@ -6,6 +6,10 @@ WORKDIR /app
COPY package*.json ./
RUN npm install
# Copy entrypoint script first
COPY docker-entrypoint.sh /app/
RUN chmod +x /app/docker-entrypoint.sh
# Copy app source
COPY . .
@@ -15,15 +19,6 @@ RUN mkdir -p /app/data /app/public/uploads && \
chmod -R 755 /app && \
chmod -R 777 /app/data /app/public/uploads
# Create an entrypoint script
RUN echo '#!/bin/sh\n\
mkdir -p /app/data\n\
mkdir -p /app/public/uploads\n\
chmod -R 777 /app/data\n\
chmod -R 777 /app/public/uploads\n\
exec node server.js' > /app/docker-entrypoint.sh && \
chmod +x /app/docker-entrypoint.sh
# Switch to non-root user
USER node
+6
View File
@@ -0,0 +1,6 @@
#!/bin/sh
mkdir -p /app/data
mkdir -p /app/public/uploads
chmod -R 777 /app/data
chmod -R 777 /app/public/uploads
exec node server.js