Skip to content

Commit

Permalink
chore: clean up gh workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
nicovandenhooff committed Apr 22, 2022
1 parent 496a87f commit fbf0a6c
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 14 deletions.
17 changes: 9 additions & 8 deletions .github/workflows/ci-cd.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# continuous integration and deployment for the deployment branch
name: ci-cd

on:
Expand All @@ -9,15 +10,15 @@ jobs:
ci:
runs-on: ubuntu-latest
steps:
- name: checkout-branch
- name: Checkout deployment branch
uses: actions/checkout@v3
with:
ref: deployment
- name: setup-python
- name: Setup Python
uses: actions/setup-python@v3
with:
python-version: '3.9.7'
- name: install-and-test
- name: Install requirements and perform tests
working-directory: api
run: |
python -m pip install --upgrade pip
Expand All @@ -28,11 +29,11 @@ jobs:
needs: ci
runs-on: ubuntu-latest
steps:
- name: checkout-deployment-branch
- name: Checkout deployment branch
uses: actions/checkout@v3
with:
ref: deployment
- name: heroku-deployment
- name: Deploy backend to Heroku
uses: AkhileshNS/heroku-deploy@v3.12.12
with:
heroku_api_key: ${{secrets.HEROKU_API_KEY}}
Expand All @@ -46,16 +47,16 @@ jobs:
env:
REACT_APP_API_ENDPOINT: ${{secrets.BACKEND}}
steps:
- name: checkout-deployment-branch
- name: Checkout deployment branch
uses: actions/checkout@v3
with:
ref: deployment
- name: install-and-build-front-end
- name: Install requirements and build frontend
working-directory: client
run: |
yarn install
npm run build
- name: gh-pages-deployment
- name: Deploy frontend to GitHub pages
uses: JamesIves/github-pages-deploy-action@v4.3.0
with:
branch: gh-pages
Expand Down
13 changes: 7 additions & 6 deletions .github/workflows/ci.yml → .github/workflows/ci-main.yml
Original file line number Diff line number Diff line change
@@ -1,23 +1,24 @@
name: ci
# continuous integration for main
name: ci-main

on:
push:
branches: [ main ]
branches: main
pull_request:
branches: [ main ]
branches: main
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: checkout-branch
- name: Checkout main
uses: actions/checkout@v3
- name: setup-python
- name: Setup Python
uses: actions/setup-python@v3
with:
python-version: '3.9.7'
- name: install-and-test
- name: Install requirements and perform tests
working-directory: api
run: |
python -m pip install --upgrade pip
Expand Down

0 comments on commit fbf0a6c

Please sign in to comment.