diff --git a/infrastructure/deploy/deploy.sh b/infrastructure/deploy/deploy.sh index 06c378c..5a14e9a 100755 --- a/infrastructure/deploy/deploy.sh +++ b/infrastructure/deploy/deploy.sh @@ -126,6 +126,9 @@ run_containers() { -e "DATABASE_URL=$DATABASE_URL" \ -e "JWT_SECRET=$JWT_SECRET" \ -e "CORS_ORIGINS=$CORS_ORIGINS" \ + -e "SOFTWARE_DIR=/app/infrastructure/software-releases" \ + -e "AGENT_RELEASES_DIR=/app/infrastructure/agent-releases" \ + -e "INSTALLER_DIR=/app/infrastructure/installer" \ fleetforge/api:latest log "starting worker" diff --git a/infrastructure/docker/Dockerfile.api b/infrastructure/docker/Dockerfile.api index 54d21c9..9a2684d 100644 --- a/infrastructure/docker/Dockerfile.api +++ b/infrastructure/docker/Dockerfile.api @@ -23,6 +23,8 @@ COPY --from=builder /app/node_modules ./node_modules COPY --from=builder /app/apps/api/node_modules ./apps/api/node_modules COPY --from=builder /app/apps/api/dist ./apps/api/dist COPY --from=builder /app/apps/api/package.json ./apps/api/ +RUN mkdir -p /app/infrastructure/software-releases /app/infrastructure/agent-releases /app/infrastructure/installer \ + && chown -R fleetforge:fleetforge /app/infrastructure USER fleetforge EXPOSE 3000 CMD ["node", "apps/api/dist/index.js"]