Merge pull request #128 from COS301-SE-2023/api_refactor_dev #211
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: Deploys, everything has already been tested | |
on: | |
push: | |
branches: | |
- redesign_dev | |
- dev | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout Code | |
uses: actions/checkout@v2 | |
- run: echo "${{ secrets.DOTENVFILE }}" > .env | |
- run: 'yarn install' | |
- run: 'yarn nx run-many --target=lint --all --parallel --skip-nx-cache' | |
- run: 'yarn nx run-many --target=build --all --parallel --skip-nx-cache' | |
- name: Connect to server and trigger update | |
uses: appleboy/ssh-action@master | |
with: | |
host: ${{ secrets.HOST}} | |
username: ${{ secrets.USERNAME }} | |
key: ${{ secrets.KEY }} | |
script: | | |
sudo /root/deploy.sh dev |