Django web server providing Mike Green's recipes.
Note This project is no longer publicly hosted
Local testing steps are identical to the production testing steps.
Launch the application and associated database using Docker:
docker-compose up
- Python 3.8+
- (Optional) Transcrypt
Platypus requires several environment variables to be set before any interaction with the system can be carried out (including testing). These can either be set manually using standard IDE or OS methods, or the values can be automatically decrypted and utilised using Transcrypt.
The following environment variable must be set before running
DB_HOST
: Host URL of database.DB_NAME
: Name of database.DB_USER
: User with read access in the database.DB_PASSWORD
: Password of the database user.SECRET_KEY
: Cryptographic key for signing.DEBUG
: Enables or disables debug mode. Application will return HTTP 500 to all requests if deployed with debug mode enabled.
To use Transcrypt, you must know the password. If you don't, give up and use the manual approach above.
- Install Transcrypt according to the official documentation.
- Initialise the repository:
transcrypt -c aes-256-cbc -p '[PASSWORD]'
Platypus requires a PostgreSQL instance to store recipe data. A simple fresh instance with some database and user is sufficient to start with.
Run the following to (re)initialise the PostgreSQL database referenced in the environment variables:
./reset-database.sh
This will destroy any existing database, run all migrations, and populate it with data.
Run all tests:
./test.sh
Launch the server:
./run.sh
If you wish to contribute to Platypus, please see the Contributing Guidelines.