This file contains 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 Poker Tool Frontend | |
on: | |
push: | |
branches: | |
- workflow | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
node-version: [14.21.3] | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Display Node.js Version | |
run: | | |
echo "Node.js version: $(node --version)" | |
- name: Setup SSH | |
uses: webfactory/ssh-agent@v0.5.4 | |
with: | |
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }} | |
- name: SSH to DigitalOcean Droplet | |
run: | | |
ssh -o StrictHostKeyChecking=no root@146.190.150.213 'cd /home/poker-tool && git pull origin workflow && yarn build' | |
# - name: Restart Nginx | |
# run: | | |
# ssh -o StrictHostKeyChecking=no user@droplet_ip_address 'sudo systemctl restart nginx' |