Skip to content

Commit

Permalink
[refactor] #251 - Jenkinsfile에 자동으로 호스트 키를 신뢰하도록 옵션 추가 (#253)
Browse files Browse the repository at this point in the history
* [#251] refactor(Jenkinsfile): scp 방식으로 리팩토링

* [#251] refactor(Jenkinsfile): 자동으로 호스트 키를 신뢰하도록 옵션 추가
  • Loading branch information
hoonyworld authored Nov 21, 2024
1 parent 93fe5b6 commit c382646
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -83,8 +83,8 @@ pipeline {

// Jenkins 서버에서 원격 서버로 파일 복사
sh """
scp -i ${KEY_FILE} /home/ubuntu/deployment/deploy-${OPERATION_ENV}.sh ${USERNAME}@${HOST}:/home/ubuntu/deployment
scp -i ${KEY_FILE} /home/ubuntu/nginx.conf ${USERNAME}@${HOST}:/home/ubuntu
scp -o StrictHostKeyChecking=no -i ${KEY_FILE} /home/ubuntu/deployment/deploy-${OPERATION_ENV}.sh ${USERNAME}@${HOST}:/home/ubuntu/deployment
scp -o StrictHostKeyChecking=no -i ${KEY_FILE} /home/ubuntu/nginx.conf ${USERNAME}@${HOST}:/home/ubuntu
"""

// 환경변수를 넘기고 deploy.sh 실행
Expand Down

0 comments on commit c382646

Please sign in to comment.