Implement back-end with django (#14) #23
This file contains hidden or 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: Back-end | |
| on: | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - back-end/** | |
| pull_request: | |
| branches: | |
| - main | |
| paths: | |
| - back-end/** | |
| jobs: | |
| images: | |
| name: Build and test image | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v3 | |
| - name: Test back-end image | |
| run: | | |
| docker build back-end/ -t back-end | |
| docker run -d -p 5000:8000 --name server back-end | |
| ./back-end/test.sh | |
| - name: Teardown back-end image test | |
| if: always() | |
| run: | | |
| docker rm -f server |