Mentions légales du service

Skip to content

Further cleaning & integration in the django container

BAIRE Anthony requested to merge abaire into django
  • this PS formalises the definition, documentation and loading of env variables

    • env variables are defined in 'config/env.py', this includes:

      • their default value
      • their documentation
    • the loaded variables are stored as attributes of this module (eg: config.env.ALLGO_DEBUG)

    • all variables are guaranteed to be set once the module is loaded thus, the config.settings (and other modules) just has to use env.ALLGO_XXXXX

    • the sphinx documentation of the variables is generated directly from the source code

  • remove supervisor, now django is run in the foreground of the container with its stdout/stderr sent to the console. Nginx is launched in the background and a healthcheck command ensures it runs fine.

  • configure static files to be served by nginx in production

  • http server (gunicorn or django) selectable with ALLGO_HTTP_SERVER

  • the secret key is now generated and rotate automatically

  • all token-related variables renamed as ALLGO_TOKEN_XXXXX

  • use debian's gunicorn package

more details in the commit messages

Edited by BAIRE Anthony

Merge request reports