c4thbc #552
Workflow file for this run
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: test | |
on: [push, pull_request, workflow_dispatch] | |
jobs: | |
prod: | |
runs-on: ubuntu-latest | |
if: github.ref == 'refs/heads/main' | |
steps: | |
- name: Pushing build to NYC | |
uses: fifsky/ssh-action@master | |
with: | |
command: | | |
cd GamesmanUni | |
echo "Fetching from remote --------------------------------------------------" | |
git fetch -v | |
echo "Pulling from GitHub ---------------------------------------------------" | |
git reset --hard origin/main | |
echo "Checking and installing new dependencies ------------------------------" | |
nvm use 18 | |
yarn install | |
echo "Building prod ---------------------------------------------------------" | |
yarn build | |
echo "Pushing to prod -------------------------------------------------------" | |
sudo /bin/rsync -au /home/github/GamesmanUni/dist/ /var/www/html/uni/ | |
host: nyc.cs.berkeley.edu | |
port: 2222 | |
user: github | |
key: ${{ secrets.KEY }} | |
pass: ${{ secrets.PASS }} |