src dir, adaptations
All checks were successful
Build and publish farmacia-bot images / Build and push client's image to Gitea's registry (push) Successful in 17s
Build and publish farmacia-bot images / deploy_ovh (push) Successful in 23s

This commit is contained in:
Giancarmine Salucci
2025-04-15 17:37:27 +02:00
parent 15a2d61ed9
commit 24c99c2d58
6 changed files with 21 additions and 15 deletions

View File

@@ -1,15 +1,18 @@
FROM node:23-alpine
WORKDIR /home/node
USER node
WORKDIR /home/node
RUN mkdir -p app/logs && chown -R node:node app
WORKDIR /home/node/app
COPY --chown=node:node package*.json ./
RUN npm install
COPY --chown=node:node main.js util.js worker.js ./
# Expose logs directory as a volume
COPY --chown=node:node src ./
VOLUME ["/home/node/app/logs"]
# Use an environment variable for thread count (default to 0 to use auto)
ENV THREAD_COUNT=0
# Run the application - using JSON array format
CMD ["sh", "-c", "node main.js ${THREAD_COUNT}"]