Skip to content

Commit

Permalink
add workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
Dhrumil-Gohil committed Aug 22, 2024
1 parent c21c6d6 commit 0ce9116
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/deployapp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,6 @@ jobs:
run: |
echo "${{ secrets.EC2_KEY }}" > ~/ec2-key.pem
chmod 600 ~/ec2-key.pem
sudo scp -o StrictHostKeyChecking=no -i ~/ec2-key.pem -r build/* ${{ secrets.EC2_USER }}@${{ secrets.EC2_HOST }}:/var/www/html
sudo ssh -o StrictHostKeyChecking=no -i ~/ec2-key.pem ${{ secrets.EC2_USER }}@${{ secrets.EC2_HOST }} 'sudo systemctl restart nginx'
scp -o StrictHostKeyChecking=no -i ~/ec2-key.pem -r build/* root@${{ secrets.EC2_HOST }}:/var/www/html
ssh -o StrictHostKeyChecking=no -i ~/ec2-key.pem ${{ secrets.EC2_USER }}@${{ secrets.EC2_HOST }} 'sudo systemctl restart nginx'

0 comments on commit 0ce9116

Please sign in to comment.