Skip to content
This repository has been archived by the owner on Sep 3, 2024. It is now read-only.

Commit

Permalink
fix: Update Dockerfile to deploy as part of startup
Browse files Browse the repository at this point in the history
  • Loading branch information
mariusbegby committed Aug 20, 2023
1 parent 054a07d commit 6837ec6
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,9 @@ COPY . .
RUN --mount=type=cache,target=/root/.npm \
npm ci --omit=dev

# Deploy Slash Commands to Discord API
RUN npm run deploy
# Cleanup of unneeded packages and apk cache
RUN apk del python3 make build-base git && \
rm -rf /var/cache/apk/* /tmp/*

# Startup command to run the bot
CMD [ "npm", "run", "start" ]
# Startup command to run the bot after deploying slash commands
CMD /bin/sh -c "npm run deploy && npm run start"

0 comments on commit 6837ec6

Please # to comment.