Cleanup and add safe utility functions (#154)
* Cleanup and add safe utility functions * Fix npm command * Update version * Fix an issue with dist builds caching * Update version
This commit is contained in:
parent
542488799f
commit
78db148150
21 changed files with 285 additions and 183 deletions
11
Dockerfile
11
Dockerfile
|
|
@ -50,17 +50,18 @@ RUN apk add --no-cache --virtual .runtime-deps \
|
|||
# Set working directory
|
||||
WORKDIR /app
|
||||
|
||||
# Copy backend
|
||||
COPY ./backend/ /app/backend/
|
||||
RUN chmod +x /app/backend/cmd/start.sh
|
||||
|
||||
# Copy frontend
|
||||
RUN rm -rf /app/backend/dist
|
||||
COPY --from=builder --chown=app:app /app/dist ./backend/dist
|
||||
COPY --from=builder --chown=app:app /app/public/locales ./backend/dist/locales
|
||||
|
||||
# Copy backend dependencies
|
||||
COPY --from=builder --chown=app:app /app/backend/node_modules ./backend/node_modules
|
||||
|
||||
# Copy backend
|
||||
COPY ./backend/ /app/backend/
|
||||
RUN chmod +x /app/backend/cmd/start.sh
|
||||
|
||||
# Create necessary directories
|
||||
RUN mkdir -p /app/backend/db /app/backend/certs && \
|
||||
chown -R app:app /app
|
||||
|
|
@ -94,4 +95,4 @@ HEALTHCHECK --interval=60s --timeout=3s --start-period=10s --retries=2 \
|
|||
# Use dumb-init for proper signal handling
|
||||
ENTRYPOINT ["dumb-init", "--"]
|
||||
WORKDIR /app/backend
|
||||
CMD ["/app/backend/cmd/start.sh"]
|
||||
CMD ["/app/backend/cmd/start.sh"]
|
||||
Loading…
Add table
Add a link
Reference in a new issue