File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,18 +35,12 @@ jobs:
3535 mv "$JAR" build/libs/hidaddy.jar
3636 ls -al build/libs
3737
38- # ----- root 계정 사용, 키는 Secrets의 PEM(개행 포함) -----
39- - name : Write SSH key to file
40- run : |
41- echo "${{ secrets.EC2_KEY }}" > /tmp/deploy.pem
42- chmod 600 /tmp/deploy.pem
43-
4438 - name : Upload JAR and Service File to server (root)
4539 uses : appleboy/scp-action@v0.1.6
4640 with :
4741 host : ${{ secrets.EC2_HOST }}
48- username : root
49- key_path : /tmp/deploy.pem
42+ username : ${{ secrets.USER }}
43+ key : ${{ secrets.EC2_KEY }}
5044 source : " build/libs/hidaddy.jar,deploy/hidaddy.service"
5145 target : " /root"
5246 strip_components : 0
5549 uses : appleboy/ssh-action@v1.0.3
5650 with :
5751 host : ${{ secrets.EC2_HOST }}
58- username : root
59- key_path : /tmp/deploy.pem
52+ username : ${{ secrets.USER }}
53+ key : ${{ secrets.EC2_KEY }}
6054 script : |
6155 # SSH 연결 테스트
6256 echo "SSH connection successful"
You can’t perform that action at this time.
0 commit comments