diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index f04a63d..60c9ba4 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -13,6 +13,7 @@ jobs: uses: actions/checkout@v4 - name: Setup SSH key + id: ssh-setup uses: webfactory/ssh-agent@v0.9.0 with: ssh-private-key: ${{ secrets.NAS_SSH_KEY_ADMIN }} @@ -38,4 +39,9 @@ jobs: sudo -n /usr/sbin/nginx -t sudo -n /bin/systemctl reload nginx docker compose down || true - EOF \ No newline at end of file + EOF + + - name: Cleanup SSH agent + if: always() && steps.ssh-setup.outcome == 'success' + run: | + ssh-agent -k || true \ No newline at end of file diff --git a/README.md b/README.md index fd98a85..643a8e3 100644 --- a/README.md +++ b/README.md @@ -7,8 +7,9 @@ Ubuntu 서버용 Nginx 리버스 프록시 배포 저장소입니다. ``` nginx-deploy/ ├── .github/workflows/deploy.yml # GitHub Actions 배포 스크립트 -├── default.conf # Nginx 설정 파일 -├── docker-compose.yml # Docker Compose 정의 +├── default.conf # Docker nginx 설정 (legacy) +├── server-nginx-default # 서버 nginx 설정 파일 +├── docker-compose.yml # Docker Compose 정의 (cleanup용) └── README.md # 이 파일 ```