Create generic Make command to run Django manage.py (#886)

See https://github.com/grafana/oncall/pull/868
This commit is contained in:
Jack Jackson 2022-11-22 13:15:22 -08:00 committed by GitHub
parent 491093100a
commit c517569108
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 7 additions and 0 deletions

View file

@ -166,3 +166,6 @@ run-backend-celery:
backend-command:
$(call backend_command,$(CMD))
backend-manage-command:
$(call backend_command,python manage.py $(CMD))

View file

@ -104,6 +104,10 @@ make dbshell # opens a DB shell
make exec-engine # exec into engine container's bash
make test # run backend tests
# run Django's `manage.py` script, passing `$CMD` as arguments.
# e.g. `make backend-manage-command makemigrations` - https://docs.djangoproject.com/en/4.1/ref/django-admin/#django-admin-makemigrations
make backend-manage-command CMD="..."
# run both frontend and backend linters
# may need to run `yarn install` from within `grafana-plugin` to install several `pre-commit` dependencies
make lint