Skip to content

Commit

Permalink
chore: deployment to public servers
Browse files Browse the repository at this point in the history
  • Loading branch information
rilesdun committed Sep 24, 2023
1 parent 571fc29 commit 3d4b4b3
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ jobs:

deploy:
runs-on: ubuntu-latest
needs: [dockerhub_publish]
needs: [dockerhub_publish]
steps:
- name: SSH Key Setup
env:
Expand All @@ -163,10 +163,10 @@ jobs:
- name: Deploy on VM
run: |
ssh -o StrictHostKeyChecking=no -i deploy_key ${{ secrets.VM_USER }}@${{ secrets.VM_IP }} << 'ENDSSH'
ssh -o StrictHostKeyChecking=no -i deploy_key ${{ secrets.VM_USER }}@${{ secrets.VM_IP }} << ENDSSH
docker pull ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.get-latest-tag.outputs.tag }}
docker stop explorer-api || true
docker rm explorer-api || true
docker run -d --name my-app ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.get-latest-tag.outputs.tag }}
docker run -d --name explorer-api ${{ env.REGISTRY }}/${{ env.IMAGE_NAME }}:${{ steps.get-latest-tag.outputs.tag }}
ENDSSH

0 comments on commit 3d4b4b3

Please sign in to comment.