Skip to content

Commit

Permalink
Update auto-deployment.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
wwingyou authored Mar 24, 2024
1 parent f3db674 commit afeb66d
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions .github/workflows/auto-deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,20 +53,18 @@ jobs:
working-directory: JWT
- name: Kill current running Spring process
run: |
ssh -i private_key.pem "${username}@${host}" << EOF
ssh -i private_key.pem "${username}@${host}"
sudo chmod 755 deploy/shutdown.sh
./deploy/shutdown.sh
EOF
working-directory: JWT
- name: Send jar file to EC2
run: |
jarPath=$(./gradlew -q jarPath)
scp $jarPath "${username}@${host}:~/server.jar"
scp -i private_key.pem $jarPath "${username}@${host}:~/server.jar"
working-directory: JWT
- name: Run new uploaded jar
run: |
ssh -i private_key.pem "${username}@${host}" << EOF
ssh -i private_key.pem "${username}@${host}"
sudo chmod 755 deploy/runner.sh
./deploy/runner.sh server.jar
EOF
working-directory: JWT

0 comments on commit afeb66d

Please sign in to comment.