Skip to content

Provisioning: Migrate bootstrap, implement make reset #6800

@khvn26

Description

@khvn26

Parent epic

Part of #6797

Blocked by

Summary

Replace the existing bootstrap management command and make reset flow with the new provisioning system.

Scope

bootstrap → thin wrapper around provision

  • Create a default bootstrap YAML file (e.g. provisioning/bootstrap.yaml) that replicates the current bootstrap behaviour: create superuser + organisation + project
  • Make the bootstrap command delegate to provision with the bootstrap YAML file
  • Keep the three sub-commands (createinitialadminuser, createinitialorganisation, createinitialproject) available for backwards compatibility

make reset → flush + provision

  • Create provisioning/dev/ directory with YAML files for a rich local dev setup
  • Update make reset to:
    reset: docker-up
        poetry run python manage.py flush --no-input
        poetry run python manage.py migrate
        poetry run python manage.py createcachetable
        poetry run python manage.py provision --directory provisioning/dev/
  • Retire the seed logic from PR feat(API): Add make reset command for local development #6459 in favour of the YAML-based approach

Acceptance criteria

  • python manage.py bootstrap still works and produces the same result
  • make reset uses provisioning YAML and produces a usable dev environment
  • Old bootstrap environment variables (ADMIN_EMAIL, etc.) still work via ${VAR:default} interpolation
  • 100% test coverage for new/changed code
  • Passes make typecheck and make lint

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions