post-docker cleanup #645
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: Lint and Test | |
on: | |
push: | |
branches: | |
- develop | |
pull_request: | |
branches: | |
- develop | |
jobs: | |
lint-job: | |
name: Linting Job | |
runs-on: self-hosted | |
timeout-minutes: 30 | |
steps: | |
- name: Take ownership of repo directory | |
run: echo ${{ secrets.SUDO_PW }} | sudo -S chown -R $USER:$USER /home/gabe/actions-runner/_work/metrinome | |
- name: Checkout Code | |
uses: actions/checkout@v2 | |
- name: Stop existing docker image | |
run: cd $GITHUB_WORKSPACE/src && make stop-detached || echo continuing | |
- name: Delete existing image | |
run: docker rm detached_repl || echo continuing | |
- name: Run new docker image | |
run: cd $GITHUB_WORKSPACE/src && make run-detached | |
- id: step1 | |
run: docker exec -w /app/code detached_repl make check-lint | |
test-job: | |
name: Unit Tests Job | |
runs-on: self-hosted | |
timeout-minutes: 30 | |
steps: | |
- name: Take ownership of repo directory | |
run: echo ${{ secrets.SUDO_PW }} | sudo -S chown -R $USER:$USER /home/gabe/actions-runner/_work/metrinome | |
- name: Checkout Code | |
uses: actions/checkout@v2 | |
- name: Stop existing docker image | |
run: cd $GITHUB_WORKSPACE/src && make stop-detached || echo continuing | |
- name: Delete existing image | |
run: docker rm detached_repl || echo continuing | |
- name: Run new docker image | |
run: cd $GITHUB_WORKSPACE/src && make run-detached | |
- name: Run Tests | |
run: docker exec -w /app/code detached_repl make tests | |