Merge pull request #201 from boostcampwm-2024/dev #16
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CD | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v2 | |
| - name: server-ssh | |
| uses: appleboy/ssh-action@master | |
| with: | |
| host: ${{ secrets.SERVER_HOST }} | |
| username: ${{ secrets.SERVER_USERNAME }} | |
| key: ${{ secrets.SERVER_KEY }} | |
| port: ${{ secrets.SERVER_PORT }} | |
| script: | | |
| cd /root/web32-BooMap | |
| git pull origin main | |
| rm -f .env | |
| rm -f client/.env.production | |
| echo "${{ secrets.ENV_BE }}" > .env | |
| echo "${{ secrets.ENV_FE }}" > client/.env.production | |
| docker-compose down | |
| docker-compose up -d --build |