Skip to content

Commit

Permalink
update docker file
Browse files Browse the repository at this point in the history
  • Loading branch information
dkrest1 committed Feb 6, 2024
1 parent 0d2b114 commit 3b79bf4
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,8 @@ jobs:
run: |
echo ${{ secrets.DOCKER_PASSWORD }} | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin
docker buildx create --use
docker buildx build -t yourusername/yourapp:latest -f .
docker push yourusername/yourapp:latest
docker buildx build -t dkrest/task-manager:latest -f .
docker push dkrest/task-manager:latest
- name: SSH into EC2 Instance and Deploy
uses: appleboy/ssh-action@master
Expand All @@ -53,8 +53,8 @@ jobs:

script: |
sleep 10
docker pull yourusername/yourapp:latest
docker stop yourapp || true
docker rm yourapp || true
docker run -d -p 8080:8080 --name yourapp yourusername/yourapp:latest || (echo "Deployment failed" && exit 1)
docker pull dkrest/task-manager:latest
docker stop task-manager || true
docker rm task-manager || true
docker run -d -p 9090:9090 --name task-manager dkrest1/task-manager:latest || (echo "Deployment failed" && exit 1)

0 comments on commit 3b79bf4

Please sign in to comment.