Skip to content

Commit

Permalink
workflows: build and push to dockerhub
Browse files Browse the repository at this point in the history
  • Loading branch information
sandeshkhadka committed Jan 26, 2024
1 parent 64ea622 commit 8715b64
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 4 deletions.
22 changes: 22 additions & 0 deletions .github/workflows/deploy.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: Docker Deploy

on:
push:
branches:
- main
workflow_dispatch:

jobs:
docker:
runs-on: ubuntu-latest
steps:
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
uses: docker/build-push-action@v5
with:
push: true
tags: sandeshkhadka/roommates-backend:latest
4 changes: 0 additions & 4 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,4 @@ EXPOSE 3001
EXPOSE 3000
RUN npx prisma generate
RUN chmod +x ./startserver.sh
ENV PORT $PORT
ENV SOCKET_PORT $SOCKET_PORT
ENV DATABASE_URL $DATABASE_URL
ENV JWT_SECRET $JWT_SECRET
CMD ["npm", "run","dev"]

0 comments on commit 8715b64

Please sign in to comment.