Skip to content

Commit

Permalink
Added ssh key to workflow secret 1
Browse files Browse the repository at this point in the history
  • Loading branch information
Martin op iMac committed Oct 30, 2023
1 parent d269c19 commit 5f7abda
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/continuous-deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ jobs:
python -m pip install --upgrade pip
pip install pytest
pip install -r requirements.txt
- name: Run tests
run: |
Expand All @@ -39,9 +39,7 @@ jobs:
mkdir -p ~/.ssh
ssh-keyscan 172.233.46.163 >> ~/.ssh/known_hosts
- name: Deploy to Linode
- name: Deploy to Linode
if: ${{ success() }}
run: |
eval "$(ssh-agent -s)"
echo "${{ secrets.SSH_PRIVATE_KEY }}" | ssh-add -
ssh -o "StrictHostKeyChecking no" -A [email protected] 'cd /var/www/html/ && git pull origin main && systemctl restart gunicorn && systemctl restart nginx && gunicorn main:app --bind 0.0.0.0'
ssh [email protected] 'cd /var/www/html/ && git pull origin main && systemctl restart gunicorn && systemctl restart nginx && gunicorn main:app --bind 0.0.0.0'

0 comments on commit 5f7abda

Please sign in to comment.