feat: Update publication timeline stages with additional details and … #55
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: Deploy CV Builder | |
| on: | |
| push: | |
| branches: | |
| - main | |
| jobs: | |
| deploy: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repo | |
| uses: actions/checkout@v3 | |
| - name: Set up Node.js | |
| uses: actions/setup-node@v3 | |
| with: | |
| node-version: 20 | |
| - name: Build frontend | |
| working-directory: ./frontend | |
| run: | | |
| npm install | |
| npm run build | |
| - name: Deploy to server via SSH | |
| uses: appleboy/ssh-action@v0.1.9 | |
| with: | |
| host: ${{ secrets.SERVER_IP }} | |
| username: ${{ secrets.SERVER_USER }} | |
| key: ${{ secrets.SERVER_SSH_KEY }} | |
| script: | | |
| cd ~/next-steps-cv-builder | |
| git pull origin main | |
| cd frontend | |
| npm install | |
| npm run build | |
| sudo rm -rf /var/www/html/* | |
| sudo cp -r dist/* /var/www/html/ | |
| cd ../backend | |
| npm install | |
| pm2 restart backend | |
| sudo systemctl reload nginx |