Device Management Studio for Beehive v2
Right now, this is a proof of concept: it has the database design codified in a Django app so that we have a simple way to write up tests to prove the design.
It's also a decent enough platform to design applications on top of, so assuming this works out we can just roll with it.
Why? Because packaging and dependency management is broken beyond belief in the Python world, and this injects so sanity and standards.
Here's a super quick run through:
pipenv install
to install the runtime deps in the Pipfilepipenv install --dev
to install the development deps in the Pipfilepipenv install <package name>
to install a runtime app dependencypipenv install --dev <package name>
to install a dev dependencypipenv shell
to wrap your shell in the python virtualenvpipenv run <command>
to wrap your command with the virtualenv
This requires PostGIS to run. The easiest way to get that up and running (and configured for the app) is using Docker:
$ docker pull mdillon/postgis
$ docker run -p 5432:5432 -e POSTGRES_PASSWORD=password -e POSTGRES_DB=waggle_manager mdillon/postgis
You'll then need to run the migrations:
$ pipenv run python manage.py migrate
Once you've stood up your database, you can run the dev server with:
$ pipenv run python manage.py runserver
If you haven't created a superuser yet, you can do that with:
$ pipenv run python manage.py createsuperuser
As of now, all we have is the built in admin site: http://localhost:8000/admin .
You guessed it:
$ pipenv run python manage.py test