Skip to content

Commit

Permalink
Add run targets
Browse files Browse the repository at this point in the history
* `dev.run` starts the service in the foreground.
* `dev.run-detached` starts the service in detached mode.
  • Loading branch information
Adolfo R. Brandes authored and arbrandes committed Sep 21, 2020
1 parent fa421c7 commit aaf5a6b
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,12 @@ dev.provision: # Provision Blockstore service
docker exec -t edx.${OPENEDX_PROJECT_NAME}.mysql /bin/bash -c 'mysql -uroot <<< "create database if not exists blockstore_db;"'
docker-compose ${BLOCKSTORE_DOCKER_COMPOSE_OPTS} exec blockstore /bin/bash -c 'source ~/.bashrc && make requirements && make migrate'

dev.run: dev.up # Run the service in the foreground
docker-compose ${BLOCKSTORE_DOCKER_COMPOSE_OPTS} exec blockstore /blockstore/venv/bin/python /blockstore/app/manage.py runserver 0.0.0.0:18250

dev.run-detached: dev.up # Run the service in the background
docker-compose ${BLOCKSTORE_DOCKER_COMPOSE_OPTS} exec -d blockstore /blockstore/venv/bin/python /blockstore/app/manage.py runserver 0.0.0.0:18250

stop: # Stop Blockstore container
docker-compose ${BLOCKSTORE_DOCKER_COMPOSE_OPTS} stop

Expand Down

0 comments on commit aaf5a6b

Please sign in to comment.