Skip to content

Commit

Permalink
cahnge ssh command sequence
Browse files Browse the repository at this point in the history
  • Loading branch information
devout-coder committed Sep 7, 2024
1 parent 7d4f776 commit 242c826
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,11 @@ jobs:
needs: build

steps:
# Adding SSH key
- name: Add SSH Key
run: |
echo "${{ secrets.EC2_KEY }}" | tr -d '\r' > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa
# SSH into EC2 and use docker-compose
- name: Deploy to EC2 using Docker Compose
run: |
Expand All @@ -56,8 +61,3 @@ jobs:
env:
EC2_KEY: ${{ secrets.EC2_KEY }}

# Adding SSH key
- name: Add SSH Key
run: |
echo "${{ secrets.EC2_KEY }}" | tr -d '\r' > ~/.ssh/id_rsa
chmod 600 ~/.ssh/id_rsa

0 comments on commit 242c826

Please sign in to comment.