Skip to content

docs(readme): update header #138

docs(readme): update header

docs(readme): update header #138

Workflow file for this run

name: CI/CD
on:
push:
branches:
- main
- v2
permissions:
checks: write
contents: write
jobs:
run-linters:
name: Run linters
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v3
- name: Setup Node
uses: actions/[email protected]
- name: Install dependencies
run: cd frontend && npm install --package-lock-only && npm ci
deploy:
name: Build
needs: run-linters
runs-on: ubuntu-latest
steps:
- name: Install ssh keys
run: |
install -m 600 -D /dev/null ~/.ssh/id_rsa
echo "${{ secrets.SSH_PRIVATE_KEY }}" > ~/.ssh/id_rsa
ssh-keyscan -H ${{ secrets.SSH_HOST }} > ~/.ssh/known_hosts
- name: Connect and Pull
run: |
if [ $GITHUB_REF == 'refs/heads/main' ]; then
ssh ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} "cd ${{ secrets.WORK_DIR }} && git checkout main && git pull --rebase && npm install && npm ci && npm run build && exit"
else
ssh ${{ secrets.SSH_USER }}@${{ secrets.SSH_HOST }} "cd ${{ secrets.TEST_WORK_DIR }} && git checkout ${GITHUB_REF##*/} && git pull && npm install && npm ci && npm run build && exit"
fi
- name: Cleanup
run: rm -rf ~/.ssh