Skip to content

Merge pull request #352 from maykinmedia/feature/json-merge-patch #585

Merge pull request #352 from maykinmedia/feature/json-merge-patch

Merge pull request #352 from maykinmedia/feature/json-merge-patch #585

Workflow file for this run

name: quick-start
on: [push]
jobs:
run:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v2
- name: Download docker-compose file
run: wget https://raw.githubusercontent.com/maykinmedia/objects-api/master/docker-compose-quickstart.yml -O docker-compose-qs.yml
- name: Overwrite the docker-compose file to get the "current" one
run: cp docker-compose-quickstart.yml docker-compose-qs.yml
- name: Start docker containers
run: docker-compose -f docker-compose-qs.yml up -d
- name: Wait until DB container starts
run: sleep 10
- name: Load fixtures
run: docker-compose -f docker-compose-qs.yml exec -T web src/manage.py loaddata demodata
- name: Create superuser
run: docker-compose -f docker-compose-qs.yml exec -T web src/manage.py createsuperuser --username admin --email admin@admin.nl --no-input
- name: Check main page
run: |
curl_status=$(curl -w '%{http_code}' -o /dev/null -s http://localhost:8000/)
if [[ $curl_status != 200 ]]; then
printf "Index page responds with ${curl_status} status.\r\n\r\n" >&2
curl -i http://localhost:8000
exit 1
fi