octopize.deploy_tool 2.6.0__tar.gz → 2.7.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/.gitignore +2 -2
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/PKG-INFO +2 -4
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/pyproject.toml +24 -35
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/__init__.py +1 -3
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/__init__.py +1 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/apply_command.py +137 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/checks.py +362 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/commands/install_command.py +219 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/commands/migrate_command.py +344 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/commands/subcommand_ports.py +59 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/commands/update_command.py +273 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/configure_command.py +257 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/configure_resume_policy.py +70 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/deployment_paths.py +91 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/diff_command.py +495 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/ports.py +357 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/render_command.py +234 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/application/start_command.py +165 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/cli.py +1284 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/cli_test_harness.py +1 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/configurator.py +1 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/configure.py +1 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/defaults.yaml +1 -1
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/domain/__init__.py +1 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/domain/configure_preset.py +52 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/domain/deployment_item.py +131 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/domain/deployment_item_registry.py +496 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/domain/deployment_state.py +68 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/domain/validation.py +115 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/domain/version_id.py +69 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/generate_env_paths.py +1 -1
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/__init__.py +1 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/configurator_runner_adapter.py +244 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/current_version_resolver.py +39 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/docker_client.py +116 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/filesystem_directory_copier.py +73 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/filesystem_directory_reader.py +34 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/filesystem_file_writer.py +35 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/filesystem_legacy_source.py +81 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/filesystem_symlink_updater.py +34 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/in_memory_state_repository.py +51 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/noop_docker_client.py +47 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/package_defaults_source.py +28 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/package_template_provider.py +41 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/package_version_provider.py +13 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/preset_loader.py +186 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/system_clock.py +13 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/yaml_config_source.py +45 -0
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/infra/yaml_state_repository.py +121 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/input_gatherer.py +7 -5
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/normalizers.py +43 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/printer.py +45 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/public_url.py +5 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/api_local_source.py +2 -2
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/authentik.py +11 -2
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/base.py +9 -106
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/email.py +64 -53
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/local_source.py +2 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/nginx.py +11 -17
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/required.py +9 -4
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/telemetry.py +39 -25
- octopize_deploy_tool-2.7.0/src/octopize_avatar_deploy/steps/user.py +20 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/_env_fragment_api.template +9 -12
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/api.env.template +8 -8
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/docker-compose.yml.template +2 -14
- octopize_deploy_tool-2.7.0/tests/TESTING.md +574 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/conftest.py +21 -138
- {octopize_deploy_tool-2.6.0/tests/fixtures/config_round_trip_first → octopize_deploy_tool-2.7.0/tests/fixtures/basic_deployment}/expected/.deployment-state.yaml +26 -26
- {octopize_deploy_tool-2.6.0/tests/fixtures/config_round_trip_second → octopize_deploy_tool-2.7.0/tests/fixtures/basic_deployment}/expected/.env +20 -23
- {octopize_deploy_tool-2.6.0/tests/fixtures/config_round_trip_first → octopize_deploy_tool-2.7.0/tests/fixtures/basic_deployment}/expected/docker-compose.yml +4 -16
- octopize_deploy_tool-2.7.0/tests/fixtures/basic_deployment/input.yaml +17 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry → octopize_deploy_tool-2.7.0/tests/fixtures/basic_deployment}/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/.deployment-state.yaml +26 -26
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/.env +20 -23
- {octopize_deploy_tool-2.6.0/tests/fixtures/basic_deployment → octopize_deploy_tool-2.7.0/tests/fixtures/cloud_storage}/expected/docker-compose.yml +4 -16
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/input.yaml +0 -1
- {octopize_deploy_tool-2.6.0/tests/fixtures/basic_deployment → octopize_deploy_tool-2.7.0/tests/fixtures/cloud_storage}/output.txt +0 -1
- {octopize_deploy_tool-2.6.0/tests/fixtures/config_round_trip_second → octopize_deploy_tool-2.7.0/tests/fixtures/config_round_trip_first}/expected/.deployment-state.yaml +26 -26
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/.env +20 -23
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/deployment-config.yaml +13 -12
- {octopize_deploy_tool-2.6.0/tests/fixtures/cloud_storage → octopize_deploy_tool-2.7.0/tests/fixtures/config_round_trip_first}/expected/docker-compose.yml +4 -16
- {octopize_deploy_tool-2.6.0/tests/fixtures/basic_deployment → octopize_deploy_tool-2.7.0/tests/fixtures/config_round_trip_second}/expected/.deployment-state.yaml +26 -26
- {octopize_deploy_tool-2.6.0/tests/fixtures/basic_deployment → octopize_deploy_tool-2.7.0/tests/fixtures/config_round_trip_second}/expected/.env +20 -23
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/docker-compose.yml +4 -16
- octopize_deploy_tool-2.7.0/tests/fixtures/configure_happy_path/expected/.deployment_states/v1/deployment_state.yaml +226 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/configure_happy_path/output.txt +71 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/.deployment-state.yaml +32 -32
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/.env +20 -23
- octopize_deploy_tool-2.7.0/tests/fixtures/dev_mode_deployment/expected/docker-compose.yml +592 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/input.yaml +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/output.txt +0 -1
- octopize_deploy_tool-2.7.0/tests/fixtures/diff_integration/from/.env +3 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/diff_integration/from/nginx/nginx.conf +5 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/diff_integration/output.txt +29 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/diff_integration/to/.env +3 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/diff_integration/to/docker-compose.yml +4 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/diff_integration/to/nginx/nginx.conf +5 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/generate_env_output_dir_error/output.txt +3 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/help/output.txt +26 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/.env +21 -24
- octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output/.permissions.json +33 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output/docker-compose.yml +592 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output/.env +89 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output/.permissions.json +33 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output/docker-compose.yml +592 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output/nginx/nginx.conf +112 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/invalid_port_config/output.txt +0 -1
- octopize_deploy_tool-2.7.0/tests/fixtures/missing_subcommand/output.txt +3 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/no_telemetry/expected/.deployment-state.yaml +26 -26
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/no_telemetry/expected/.env +20 -23
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/branding/favicon.ico +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/branding/logo.png +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/custom-templates/email_account_confirmation.html +93 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/custom-templates/email_account_exists.html +126 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/custom-templates/email_account_invitation.html +159 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/custom-templates/email_forgotten_password.html +124 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/custom-templates/email_password_changed.html +111 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/custom-templates/email_password_reset.html +109 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/octopize-avatar-blueprint.yaml +1738 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/authentik/translations.json +24 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry/expected/docker-compose.yml +592 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/no_telemetry/input.yaml +0 -1
- {octopize_deploy_tool-2.6.0/tests/fixtures/output_dir_nested → octopize_deploy_tool-2.7.0/tests/fixtures/no_telemetry}/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/non_interactive_complete/config.yaml +5 -3
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/non_interactive_complete/expected/.deployment-state.yaml +30 -32
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/.env +89 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/branding/favicon.ico +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/branding/logo.png +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/custom-templates/email_account_confirmation.html +93 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/custom-templates/email_account_exists.html +126 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/custom-templates/email_account_invitation.html +159 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/custom-templates/email_forgotten_password.html +124 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/custom-templates/email_password_changed.html +111 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/custom-templates/email_password_reset.html +109 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/octopize-avatar-blueprint.yaml +1738 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/authentik/translations.json +24 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/docker-compose.yml +592 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/non_interactive_complete/expected/nginx/nginx.conf +112 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/non_interactive_complete/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/non_interactive_incomplete_config/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/non_interactive_partial_config/output.txt +0 -1
- {octopize_deploy_tool-2.6.0/tests/fixtures/cloud_storage → octopize_deploy_tool-2.7.0/tests/fixtures/output_dir_nested}/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/prompt_help/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/resume_interrupted/input_resume.yaml +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/resume_interrupted/resume/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/save_config_interactive/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/save_config_with_existing/input.yaml +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/save_config_with_existing/output.txt +0 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/template_from_local_verbose/output.txt +1 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/type_mismatch_config/output.txt +0 -1
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/base_v1/generated_files/.env +89 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/.env +89 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/.permissions.json +33 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/branding/favicon.ico +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/branding/logo.png +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/custom-templates/email_account_confirmation.html +93 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/custom-templates/email_account_exists.html +126 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/custom-templates/email_account_invitation.html +159 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/custom-templates/email_forgotten_password.html +124 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/custom-templates/email_password_changed.html +111 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/custom-templates/email_password_reset.html +109 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/octopize-avatar-blueprint.yaml +1738 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/authentik/translations.json +24 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/docker-compose.yml +592 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_apply_output/nginx/nginx.conf +112 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/.env +89 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/.permissions.json +33 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/branding/favicon.ico +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/branding/logo.png +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/custom-templates/email_account_confirmation.html +93 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/custom-templates/email_account_exists.html +126 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/custom-templates/email_account_invitation.html +159 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/custom-templates/email_forgotten_password.html +124 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/custom-templates/email_password_changed.html +111 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/custom-templates/email_password_reset.html +109 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/octopize-avatar-blueprint.yaml +1738 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/authentik/translations.json +24 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/docker-compose.yml +592 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_interactive_diff/expected_render_output/nginx/nginx.conf +112 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/base_v1/generated_files/.env +89 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/.env +89 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/.permissions.json +33 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/branding/favicon.ico +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/branding/logo.png +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/custom-templates/email_account_confirmation.html +93 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/custom-templates/email_account_exists.html +126 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/custom-templates/email_account_invitation.html +159 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/custom-templates/email_forgotten_password.html +124 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/custom-templates/email_password_changed.html +111 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/custom-templates/email_password_reset.html +109 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/octopize-avatar-blueprint.yaml +1738 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/authentik/translations.json +24 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/docker-compose.yml +592 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_apply_output/nginx/nginx.conf +112 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/.env +89 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/.permissions.json +33 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/branding/favicon.ico +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/branding/logo.png +0 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/custom-templates/email_account_confirmation.html +93 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/custom-templates/email_account_exists.html +126 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/custom-templates/email_account_invitation.html +159 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/custom-templates/email_forgotten_password.html +124 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/custom-templates/email_password_changed.html +111 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/custom-templates/email_password_reset.html +109 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/octopize-avatar-blueprint.yaml +1738 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/authentik/translations.json +24 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/docker-compose.yml +592 -0
- octopize_deploy_tool-2.7.0/tests/fixtures/update_noninteractive_clean/expected_render_output/nginx/nginx.conf +112 -0
- octopize_deploy_tool-2.7.0/tests/helpers/__init__.py +1 -0
- octopize_deploy_tool-2.7.0/tests/helpers/fakes.py +333 -0
- octopize_deploy_tool-2.7.0/tests/helpers/fixture_dir_comparison.py +194 -0
- octopize_deploy_tool-2.7.0/tests/helpers/normalization.py +206 -0
- octopize_deploy_tool-2.7.0/tests/helpers/printers.py +62 -0
- octopize_deploy_tool-2.7.0/tests/integration/__init__.py +9 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/integration/test_cli_integration.py +27 -6
- octopize_deploy_tool-2.7.0/tests/integration/test_configure_command.py +690 -0
- octopize_deploy_tool-2.7.0/tests/integration/test_diff_command.py +245 -0
- octopize_deploy_tool-2.7.0/tests/integration/test_install_command.py +129 -0
- octopize_deploy_tool-2.7.0/tests/integration/test_update_command.py +288 -0
- octopize_deploy_tool-2.7.0/tests/unit/infra/__init__.py +0 -0
- octopize_deploy_tool-2.7.0/tests/unit/infra/conftest.py +70 -0
- octopize_deploy_tool-2.7.0/tests/unit/infra/test_configure_runner_adapter.py +143 -0
- octopize_deploy_tool-2.7.0/tests/unit/infra/test_filesystem_directory_copier.py +101 -0
- octopize_deploy_tool-2.7.0/tests/unit/infra/test_filesystem_legacy_source.py +62 -0
- octopize_deploy_tool-2.7.0/tests/unit/infra/test_preset_loader.py +132 -0
- octopize_deploy_tool-2.7.0/tests/unit/infra/test_yaml_config_source.py +30 -0
- octopize_deploy_tool-2.7.0/tests/unit/infra/test_yaml_deployment_state_repository.py +83 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_api_local_source.py +1 -1
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_email.py +9 -9
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_local_source.py +1 -1
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_nginx.py +16 -40
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_telemetry.py +93 -0
- octopize_deploy_tool-2.7.0/tests/unit/steps/test_user.py +41 -0
- octopize_deploy_tool-2.7.0/tests/unit/test_apply_command.py +241 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_authentik_client.py +1 -1
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_configurator.py +72 -0
- octopize_deploy_tool-2.7.0/tests/unit/test_configure_command.py +959 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_deployment_configurator.py +12 -18
- octopize_deploy_tool-2.7.0/tests/unit/test_deployment_item.py +40 -0
- octopize_deploy_tool-2.7.0/tests/unit/test_diff_command.py +785 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_generate_env_cli.py +6 -9
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_generic_prompt.py +2 -2
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_input_gatherer.py +12 -2
- octopize_deploy_tool-2.7.0/tests/unit/test_install_command.py +302 -0
- octopize_deploy_tool-2.7.0/tests/unit/test_migrate_command.py +594 -0
- octopize_deploy_tool-2.7.0/tests/unit/test_normalizers.py +42 -0
- octopize_deploy_tool-2.7.0/tests/unit/test_preflight_checks.py +526 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_public_url.py +1 -1
- octopize_deploy_tool-2.7.0/tests/unit/test_render_command.py +547 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_renderer.py +1 -5
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_rich_implementations.py +0 -5
- octopize_deploy_tool-2.7.0/tests/unit/test_update_command.py +367 -0
- octopize_deploy_tool-2.7.0/tests/unit/test_version_id.py +71 -0
- octopize_deploy_tool-2.6.0/src/octopize_avatar_deploy/cli.py +0 -422
- octopize_deploy_tool-2.6.0/src/octopize_avatar_deploy/steps/user.py +0 -67
- octopize_deploy_tool-2.6.0/tests/TESTING.md +0 -237
- octopize_deploy_tool-2.6.0/tests/fixtures/dev_mode_deployment/expected/docker-compose.yml +0 -604
- octopize_deploy_tool-2.6.0/tests/fixtures/generate_env_output_dir_error/output.txt +0 -2
- octopize_deploy_tool-2.6.0/tests/fixtures/help/output.txt +0 -13
- octopize_deploy_tool-2.6.0/tests/fixtures/missing_subcommand/output.txt +0 -2
- octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected/docker-compose.yml +0 -604
- octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected/docker-compose.yml +0 -604
- octopize_deploy_tool-2.6.0/tests/integration/__init__.py +0 -1
- octopize_deploy_tool-2.6.0/tests/steps/test_user.py +0 -73
- octopize_deploy_tool-2.6.0/tests/steps/test_user_validation.py +0 -147
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/README.md +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/infra/deployment/deployment-tool/src/octopize_avatar_deploy/steps/user.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/authentik_migration.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/components.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/deployment_mode.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/download_templates.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/generate_env.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/output_spec.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/renderer.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/state_manager.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/__init__.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/authentik_blueprint.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/component_selection.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/database.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/logging.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/service_urls.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/storage.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/steps/target_environment.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/template_provisioning.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/.env.template +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/.template-version +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/_env_fragment_infra.template +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/_env_fragment_web.template +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/branding/favicon.ico +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/branding/logo.png +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/custom-templates/email_account_confirmation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/custom-templates/email_account_exists.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/custom-templates/email_account_invitation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/custom-templates/email_forgotten_password.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/custom-templates/email_password_changed.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/custom-templates/email_password_reset.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/octopize-avatar-blueprint.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/authentik/translations.json +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/compose.override.yaml.template +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/nginx.conf.template +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/python_client.env.template +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/templates/web.env.template +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/topology_urls.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/url_contract.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/version_compat.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/__init__.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/__init__.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/authentik_migration/licenses.csv +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/authentik_migration/organizations.csv +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/authentik_migration/users.csv +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/branding/favicon.ico +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/branding/logo.png +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/custom-templates/email_account_confirmation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/custom-templates/email_account_exists.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/custom-templates/email_account_invitation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/custom-templates/email_forgotten_password.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/custom-templates/email_password_changed.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/custom-templates/email_password_reset.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/octopize-avatar-blueprint.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/authentik/translations.json +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/basic_deployment/expected/nginx/nginx.conf +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/branding/favicon.ico +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/branding/logo.png +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/custom-templates/email_account_confirmation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/custom-templates/email_account_exists.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/custom-templates/email_account_invitation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/custom-templates/email_forgotten_password.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/custom-templates/email_password_changed.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/custom-templates/email_password_reset.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/octopize-avatar-blueprint.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/authentik/translations.json +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/cloud_storage/expected/nginx/nginx.conf +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_not_found/output.txt +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/branding/favicon.ico +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/branding/logo.png +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/custom-templates/email_account_confirmation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/custom-templates/email_account_exists.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/custom-templates/email_account_invitation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/custom-templates/email_forgotten_password.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/custom-templates/email_password_changed.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/custom-templates/email_password_reset.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/octopize-avatar-blueprint.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/authentik/translations.json +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_first/expected/nginx/nginx.conf +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/branding/favicon.ico +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/branding/logo.png +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/custom-templates/email_account_confirmation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/custom-templates/email_account_exists.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/custom-templates/email_account_invitation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/custom-templates/email_forgotten_password.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/custom-templates/email_password_changed.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/custom-templates/email_password_reset.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/octopize-avatar-blueprint.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/authentik/translations.json +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/config_round_trip_second/expected/nginx/nginx.conf +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/basic_deployment → octopize_deploy_tool-2.7.0/tests/fixtures/configure_happy_path}/input.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/deploy_help/output.txt +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/branding/favicon.ico +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/branding/logo.png +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/custom-templates/email_account_confirmation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/custom-templates/email_account_exists.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/custom-templates/email_account_invitation.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/custom-templates/email_forgotten_password.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/custom-templates/email_password_changed.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/custom-templates/email_password_reset.html +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/octopize-avatar-blueprint.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/authentik/translations.json +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/compose.override.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/nginx/nginx.conf +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/test-.npmrc +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/test-avatar-repo/services/api/main.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/dev_mode_deployment/expected/test-avatar-website/package.json +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/generate_env_help/output.txt +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/branding/favicon.ico +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/branding/logo.png +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/custom-templates/email_account_confirmation.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/custom-templates/email_account_exists.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/custom-templates/email_account_invitation.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/custom-templates/email_forgotten_password.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/custom-templates/email_password_changed.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/custom-templates/email_password_reset.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/octopize-avatar-blueprint.yaml +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/no_telemetry/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/authentik/translations.json +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_apply_output}/nginx/nginx.conf +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/branding/favicon.ico +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/branding/logo.png +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/custom-templates/email_account_confirmation.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/custom-templates/email_account_exists.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/custom-templates/email_account_invitation.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/custom-templates/email_forgotten_password.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/custom-templates/email_password_changed.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/custom-templates/email_password_reset.html +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/octopize-avatar-blueprint.yaml +0 -0
- {octopize_deploy_tool-2.6.0/tests/fixtures/non_interactive_complete/expected → octopize_deploy_tool-2.7.0/tests/fixtures/install_render_output}/authentik/translations.json +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/invalid_port_config/config.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/invalid_url_config/config.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/invalid_url_config/output.txt +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/malformed_yaml/config.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/malformed_yaml/output.txt +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/no_telemetry/expected/nginx/nginx.conf +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/non_interactive_incomplete_config/config.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/non_interactive_no_config/output.txt +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/non_interactive_partial_config/config.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/output_dir_permission_denied/output.txt +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/prompt_help/input.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/resume_interrupted/first_run/output.txt +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/resume_interrupted/input_first_run.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/save_config_with_existing/config.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/fixtures/type_mismatch_config/config.yaml +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/integration/test_generate_env.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/test_cli_harness.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_authentik.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_authentik_blueprint.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_base.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_component_selection.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_database.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_logging.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_required.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_service_urls.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_state_manager.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_storage.py +0 -0
- {octopize_deploy_tool-2.6.0/tests → octopize_deploy_tool-2.7.0/tests/unit}/steps/test_target_environment.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_authentik_migration.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_compare_helpers.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_components.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_deployment_runner.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_output_spec.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_printer.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_step_filtering.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_topology_urls.py +0 -0
- {octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/tests/unit/test_version_validation.py +0 -0
|
@@ -67,9 +67,9 @@ Thumbs.db
|
|
|
67
67
|
.avatar-templates
|
|
68
68
|
.deployment_state.yaml
|
|
69
69
|
.env
|
|
70
|
-
!tests/fixtures
|
|
70
|
+
!tests/fixtures/**/.env
|
|
71
71
|
config.*.yaml
|
|
72
72
|
!config.example.yaml
|
|
73
|
-
|
|
73
|
+
.deployment_states/*
|
|
74
74
|
# TLS test fixtures created dynamically by the test suite
|
|
75
75
|
tls/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: octopize.deploy_tool
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.7.0
|
|
4
4
|
Summary: Deployment configuration tool for Octopize Avatar platform
|
|
5
5
|
Project-URL: Homepage, https://octopize.io
|
|
6
6
|
Project-URL: Documentation, https://docs.octopize.io/docs/deploying/self-hosted
|
|
@@ -21,11 +21,9 @@ Requires-Python: >=3.13
|
|
|
21
21
|
Requires-Dist: httpx>=0.28.0
|
|
22
22
|
Requires-Dist: jinja2>=3.1.0
|
|
23
23
|
Requires-Dist: pandas>=3.0.0
|
|
24
|
+
Requires-Dist: python-on-whales>=0.76.0
|
|
24
25
|
Requires-Dist: pyyaml>=6.0
|
|
25
26
|
Requires-Dist: rich>=13.0.0
|
|
26
|
-
Provides-Extra: dev
|
|
27
|
-
Requires-Dist: pyright>=1.1.402; extra == 'dev'
|
|
28
|
-
Requires-Dist: pytest>=7.0; extra == 'dev'
|
|
29
27
|
Description-Content-Type: text/markdown
|
|
30
28
|
|
|
31
29
|
# Octopize Avatar Deployment Tool
|
|
@@ -4,14 +4,12 @@ build-backend = "hatchling.build"
|
|
|
4
4
|
|
|
5
5
|
[project]
|
|
6
6
|
name = "octopize.deploy_tool"
|
|
7
|
-
version = "2.
|
|
7
|
+
version = "2.7.0"
|
|
8
8
|
description = "Deployment configuration tool for Octopize Avatar platform"
|
|
9
9
|
readme = "README.md"
|
|
10
10
|
requires-python = ">=3.13"
|
|
11
11
|
license = { text = "MIT" }
|
|
12
|
-
authors = [
|
|
13
|
-
{ name = "Octopize", email = "contact@octopize.io" }
|
|
14
|
-
]
|
|
12
|
+
authors = [{ name = "Octopize", email = "contact@octopize.io" }]
|
|
15
13
|
keywords = ["octopize", "avatar", "deployment", "configuration"]
|
|
16
14
|
classifiers = [
|
|
17
15
|
"Development Status :: 4 - Beta",
|
|
@@ -30,12 +28,18 @@ dependencies = [
|
|
|
30
28
|
"rich>=13.0.0",
|
|
31
29
|
"httpx>=0.28.0",
|
|
32
30
|
"pandas>=3.0.0",
|
|
31
|
+
"python-on-whales>=0.76.0",
|
|
33
32
|
]
|
|
34
33
|
|
|
35
|
-
[
|
|
34
|
+
[dependency-groups]
|
|
36
35
|
dev = [
|
|
37
|
-
"pytest>=
|
|
36
|
+
"pytest>=9",
|
|
37
|
+
"mypy>=1.20.0",
|
|
38
38
|
"pyright>=1.1.402",
|
|
39
|
+
"types-pyyaml>=6.0.12.20241230",
|
|
40
|
+
"pandas-stubs>=3.0.0",
|
|
41
|
+
"pytest-httpx>=0.36.0",
|
|
42
|
+
"pytest-cov>=7.1.0",
|
|
39
43
|
]
|
|
40
44
|
|
|
41
45
|
[project.scripts]
|
|
@@ -54,36 +58,30 @@ packages = ["src/octopize_avatar_deploy"]
|
|
|
54
58
|
"src" = ""
|
|
55
59
|
|
|
56
60
|
[tool.hatch.build.targets.sdist]
|
|
57
|
-
include = [
|
|
58
|
-
"src/",
|
|
59
|
-
"tests/",
|
|
60
|
-
"README.md",
|
|
61
|
-
"pyproject.toml",
|
|
62
|
-
]
|
|
61
|
+
include = ["src/", "tests/", "README.md", "pyproject.toml"]
|
|
63
62
|
|
|
64
63
|
[tool.pytest.ini_options]
|
|
65
64
|
# Test discovery
|
|
66
|
-
testpaths =
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
65
|
+
testpaths = "tests"
|
|
66
|
+
filterwarnings = ["error"]
|
|
67
|
+
# Recommended by pytest
|
|
68
|
+
pythonpath = "src"
|
|
70
69
|
|
|
71
70
|
# Output options
|
|
72
71
|
addopts = [
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
"--
|
|
77
|
-
"-
|
|
72
|
+
# Recommended by pytest
|
|
73
|
+
# https://docs.pytest.org/en/stable/explanation/goodpractices.html#tests-outside-application-code
|
|
74
|
+
|
|
75
|
+
"--import-mode=importlib",
|
|
76
|
+
"--strict-markers", # Error on unknown markers
|
|
77
|
+
"--tb=short", # Short traceback format
|
|
78
|
+
"--color=yes", # Colored output
|
|
79
|
+
"-ra", # Show summary of all test results
|
|
78
80
|
]
|
|
79
81
|
|
|
80
82
|
[tool.coverage.run]
|
|
81
83
|
source = ["src/octopize_avatar_deploy"]
|
|
82
|
-
omit = [
|
|
83
|
-
"*/tests/*",
|
|
84
|
-
"*/__pycache__/*",
|
|
85
|
-
"*/.venv/*",
|
|
86
|
-
]
|
|
84
|
+
omit = ["*/tests/*", "*/__pycache__/*", "*/.venv/*"]
|
|
87
85
|
|
|
88
86
|
[tool.coverage.report]
|
|
89
87
|
exclude_lines = [
|
|
@@ -99,15 +97,6 @@ exclude_lines = [
|
|
|
99
97
|
[tool.ruff]
|
|
100
98
|
extend = "../../../ruff.toml"
|
|
101
99
|
|
|
102
|
-
[dependency-groups]
|
|
103
|
-
dev = [
|
|
104
|
-
"mypy>=1.20.0",
|
|
105
|
-
"pyright>=1.1.402",
|
|
106
|
-
"types-pyyaml>=6.0.12.20241230",
|
|
107
|
-
"pandas-stubs>=3.0.0",
|
|
108
|
-
"pytest-httpx>=0.36.0",
|
|
109
|
-
]
|
|
110
|
-
|
|
111
100
|
[tool.pyright]
|
|
112
101
|
include = ["src/octopize_avatar_deploy"]
|
|
113
102
|
pythonVersion = "3.13"
|
{octopize_deploy_tool-2.6.0 → octopize_deploy_tool-2.7.0}/src/octopize_avatar_deploy/__init__.py
RENAMED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
"""Octopize Avatar Deployment Tool."""
|
|
2
2
|
|
|
3
|
-
from .cli import main
|
|
4
3
|
from .configure import DeploymentConfigurator, DeploymentRunner
|
|
5
4
|
from .printer import ConsolePrinter, Printer, SilentPrinter
|
|
6
5
|
from .version_compat import (
|
|
@@ -11,9 +10,8 @@ from .version_compat import (
|
|
|
11
10
|
validate_template_version,
|
|
12
11
|
)
|
|
13
12
|
|
|
14
|
-
__version__ = "2.
|
|
13
|
+
__version__ = "2.7.0"
|
|
15
14
|
__all__ = [
|
|
16
|
-
"main",
|
|
17
15
|
"DeploymentRunner",
|
|
18
16
|
"DeploymentConfigurator",
|
|
19
17
|
"Printer",
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"""Application sub-package for deployment tool refactor (Phase 1)."""
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
"""ApplyCommand: the Phase 1 application entry point for the apply sub-command.
|
|
2
|
+
|
|
3
|
+
``apply`` copies a fully rendered ``generated/`` directory from a versioned
|
|
4
|
+
state slot into ``generated_files/`` (the directory consumed by Docker Compose)
|
|
5
|
+
and updates the ``currently_deployed`` symlink so the active version is always
|
|
6
|
+
traceable.
|
|
7
|
+
|
|
8
|
+
The operation is idempotent: applying the same version twice produces the same
|
|
9
|
+
``generated_files/`` content and symlink target.
|
|
10
|
+
"""
|
|
11
|
+
|
|
12
|
+
from __future__ import annotations
|
|
13
|
+
|
|
14
|
+
from dataclasses import dataclass
|
|
15
|
+
from pathlib import Path
|
|
16
|
+
|
|
17
|
+
from octopize_avatar_deploy.application.deployment_paths import DeploymentPaths
|
|
18
|
+
from octopize_avatar_deploy.application.ports import DirectoryCopier, SymlinkUpdater
|
|
19
|
+
from octopize_avatar_deploy.domain.version_id import VersionId
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
class ApplyError(Exception):
|
|
23
|
+
"""Raised when apply fails due to an operator-fixable problem.
|
|
24
|
+
|
|
25
|
+
Covers missing ``--version`` argument, references to versions whose
|
|
26
|
+
``generated/`` directory does not yet exist (i.e. ``render`` was never run
|
|
27
|
+
for that version), or any filesystem error that maps to an operator action.
|
|
28
|
+
|
|
29
|
+
Distinct from plain ``ValueError`` or ``FileNotFoundError``, which indicate
|
|
30
|
+
programming-contract violations (bugs in the tool) and should surface with a
|
|
31
|
+
full traceback.
|
|
32
|
+
"""
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
@dataclass
|
|
36
|
+
class ApplyCommandArgs:
|
|
37
|
+
"""Arguments for the apply command.
|
|
38
|
+
|
|
39
|
+
``version`` must be provided (e.g. ``"v1"``).
|
|
40
|
+
"""
|
|
41
|
+
|
|
42
|
+
app_root: Path
|
|
43
|
+
version: str # explicit version label, e.g. "v1"
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
@dataclass
|
|
47
|
+
class ApplyCommandResult:
|
|
48
|
+
"""Result returned by :meth:`ApplyCommand.run`."""
|
|
49
|
+
|
|
50
|
+
version: VersionId
|
|
51
|
+
output_dir: Path
|
|
52
|
+
symlink_target: Path
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
class ApplyCommand:
|
|
56
|
+
"""Orchestrate the apply use case.
|
|
57
|
+
|
|
58
|
+
Copies ``.deployment_states/vX/generated/`` into ``generated_files/`` and
|
|
59
|
+
updates the ``currently_deployed`` symlink.
|
|
60
|
+
|
|
61
|
+
All side effects (directory copy and symlink update) are injected as ports
|
|
62
|
+
so the full use case can be exercised in tests with in-memory doubles.
|
|
63
|
+
|
|
64
|
+
Args:
|
|
65
|
+
directory_copier: Port that performs the full recursive copy from the
|
|
66
|
+
versioned ``generated/`` directory to ``generated_files/``.
|
|
67
|
+
symlink_updater: Port that creates or replaces the
|
|
68
|
+
``currently_deployed`` symlink.
|
|
69
|
+
"""
|
|
70
|
+
|
|
71
|
+
def __init__(
|
|
72
|
+
self,
|
|
73
|
+
*,
|
|
74
|
+
directory_copier: DirectoryCopier,
|
|
75
|
+
symlink_updater: SymlinkUpdater,
|
|
76
|
+
) -> None:
|
|
77
|
+
self._directory_copier = directory_copier
|
|
78
|
+
self._symlink_updater = symlink_updater
|
|
79
|
+
|
|
80
|
+
def run(self, args: ApplyCommandArgs) -> ApplyCommandResult:
|
|
81
|
+
"""Execute the apply use case end-to-end.
|
|
82
|
+
|
|
83
|
+
Flow:
|
|
84
|
+
|
|
85
|
+
1. Validate argument combinations.
|
|
86
|
+
2. Parse the target version label.
|
|
87
|
+
3. Confirm that ``render`` has been run for this version (the
|
|
88
|
+
``generated/`` directory exists).
|
|
89
|
+
4. Copy ``.deployment_states/vX/generated/`` → ``generated_files/``
|
|
90
|
+
(full recursive copy — not a symlink — so operator edits in
|
|
91
|
+
``generated_files/`` never affect the versioned reference).
|
|
92
|
+
5. Update ``.deployment_states/currently_deployed`` symlink → ``vX``.
|
|
93
|
+
6. Return a result.
|
|
94
|
+
|
|
95
|
+
Args:
|
|
96
|
+
args: Apply command arguments.
|
|
97
|
+
|
|
98
|
+
Returns:
|
|
99
|
+
:class:`ApplyCommandResult` with the resolved version, the
|
|
100
|
+
``generated_files/`` output directory, and the symlink target path.
|
|
101
|
+
|
|
102
|
+
Raises:
|
|
103
|
+
ApplyError: For any operator-fixable problem: a version whose
|
|
104
|
+
``generated/`` directory does not exist, or a missing version
|
|
105
|
+
argument.
|
|
106
|
+
"""
|
|
107
|
+
try:
|
|
108
|
+
return self._run(args)
|
|
109
|
+
except ApplyError:
|
|
110
|
+
raise
|
|
111
|
+
except (ValueError, FileNotFoundError) as exc:
|
|
112
|
+
raise ApplyError(str(exc)) from exc
|
|
113
|
+
|
|
114
|
+
def _run(self, args: ApplyCommandArgs) -> ApplyCommandResult:
|
|
115
|
+
"""Internal implementation called by :meth:`run`."""
|
|
116
|
+
# 1. Parse version.
|
|
117
|
+
version = VersionId.parse(args.version)
|
|
118
|
+
paths = DeploymentPaths(app_root=args.app_root, version=version)
|
|
119
|
+
|
|
120
|
+
# 2. Verify that render has been run (generated/ must exist).
|
|
121
|
+
if not self._directory_copier.source_exists(paths.generated_dir):
|
|
122
|
+
raise ApplyError(
|
|
123
|
+
f"Version {version.label!r} has not been rendered yet. "
|
|
124
|
+
f"Run 'render --version {version.label}' first."
|
|
125
|
+
)
|
|
126
|
+
|
|
127
|
+
# 3. Copy generated/ → generated_files/.
|
|
128
|
+
self._directory_copier.copy(paths.generated_dir, paths.generated_files_dir)
|
|
129
|
+
|
|
130
|
+
# 4. Update currently_deployed symlink.
|
|
131
|
+
self._symlink_updater.update(paths.currently_deployed_symlink, paths.version_dir)
|
|
132
|
+
|
|
133
|
+
return ApplyCommandResult(
|
|
134
|
+
version=version,
|
|
135
|
+
output_dir=paths.generated_files_dir,
|
|
136
|
+
symlink_target=paths.version_dir,
|
|
137
|
+
)
|
|
@@ -0,0 +1,362 @@
|
|
|
1
|
+
"""Pre-flight and general-purpose check infrastructure.
|
|
2
|
+
|
|
3
|
+
Provides a composable check system used by top-level commands (``install``,
|
|
4
|
+
``update``, etc.) to run ordered guard checks before executing their main
|
|
5
|
+
pipeline. Each check is an independent unit with its own dependencies and
|
|
6
|
+
returns a typed result. A :class:`PreflightCheck` orchestrates a list of
|
|
7
|
+
checks, short-circuits on the first abort, and collects results into a
|
|
8
|
+
:class:`PreflightResult`.
|
|
9
|
+
|
|
10
|
+
Architecture:
|
|
11
|
+
- :class:`CheckResult` — common Protocol; every concrete result must implement it.
|
|
12
|
+
- :class:`Check` — Protocol for runnable checks; each check receives its deps
|
|
13
|
+
at construction and exposes a ``run(app_root)`` method.
|
|
14
|
+
- :class:`VolumeCheck` / :class:`DeploymentStateCheck` — concrete checks.
|
|
15
|
+
- :class:`PreflightResult` — aggregated results with typed accessors.
|
|
16
|
+
- :class:`PreflightCheck` — orchestrator that composes a list of checks.
|
|
17
|
+
"""
|
|
18
|
+
|
|
19
|
+
from __future__ import annotations
|
|
20
|
+
|
|
21
|
+
from dataclasses import dataclass, field
|
|
22
|
+
from pathlib import Path
|
|
23
|
+
from typing import Literal, Protocol
|
|
24
|
+
|
|
25
|
+
from octopize_avatar_deploy.application.ports import (
|
|
26
|
+
DeploymentStateRepository,
|
|
27
|
+
DockerClient,
|
|
28
|
+
)
|
|
29
|
+
from octopize_avatar_deploy.input_gatherer import InputGatherer
|
|
30
|
+
from octopize_avatar_deploy.printer import Printer
|
|
31
|
+
|
|
32
|
+
# ---------------------------------------------------------------------------
|
|
33
|
+
# Known Avatar Docker volumes
|
|
34
|
+
# ---------------------------------------------------------------------------
|
|
35
|
+
|
|
36
|
+
#: The canonical set of Docker volume names created by the Avatar stack.
|
|
37
|
+
#: Passed to :class:`VolumeCheck` by default in production wiring.
|
|
38
|
+
AVATAR_KNOWN_VOLUMES: list[str] = [
|
|
39
|
+
"avatar_postgres_data",
|
|
40
|
+
"avatar_seaweedfs_data",
|
|
41
|
+
"avatar_seaweedfs_metadata",
|
|
42
|
+
"avatar_seaweedfs_blocks",
|
|
43
|
+
]
|
|
44
|
+
|
|
45
|
+
|
|
46
|
+
# ---------------------------------------------------------------------------
|
|
47
|
+
# Protocols
|
|
48
|
+
# ---------------------------------------------------------------------------
|
|
49
|
+
|
|
50
|
+
|
|
51
|
+
class CheckResult(Protocol):
|
|
52
|
+
"""Common interface for all check results.
|
|
53
|
+
|
|
54
|
+
Every concrete check result must expose an ``aborted`` attribute so that
|
|
55
|
+
:class:`PreflightResult` can aggregate outcomes without knowing the
|
|
56
|
+
specific result type.
|
|
57
|
+
"""
|
|
58
|
+
|
|
59
|
+
@property
|
|
60
|
+
def aborted(self) -> bool:
|
|
61
|
+
"""Whether this check caused the overall operation to be aborted."""
|
|
62
|
+
...
|
|
63
|
+
|
|
64
|
+
|
|
65
|
+
class Check(Protocol):
|
|
66
|
+
"""Protocol for a single runnable pre-flight check.
|
|
67
|
+
|
|
68
|
+
Implementations receive all required dependencies at construction time.
|
|
69
|
+
The ``run`` method is kept narrow: it receives only the ``app_root`` path
|
|
70
|
+
that is common to every check.
|
|
71
|
+
"""
|
|
72
|
+
|
|
73
|
+
def run(self, app_root: Path) -> CheckResult:
|
|
74
|
+
"""Execute the check and return a typed result.
|
|
75
|
+
|
|
76
|
+
Args:
|
|
77
|
+
app_root: Operator's working directory (the deployment root).
|
|
78
|
+
|
|
79
|
+
Returns:
|
|
80
|
+
A :class:`CheckResult` implementation. If ``result.aborted`` is
|
|
81
|
+
``True`` the caller should not proceed further.
|
|
82
|
+
"""
|
|
83
|
+
...
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
# ---------------------------------------------------------------------------
|
|
87
|
+
# VolumeCheck
|
|
88
|
+
# ---------------------------------------------------------------------------
|
|
89
|
+
|
|
90
|
+
|
|
91
|
+
@dataclass
|
|
92
|
+
class VolumeCheckResult:
|
|
93
|
+
"""Result of the Docker volume pre-flight check.
|
|
94
|
+
|
|
95
|
+
Attributes:
|
|
96
|
+
existing_volumes: Volume names that were found on the host.
|
|
97
|
+
aborted: ``True`` if the operator chose not to continue.
|
|
98
|
+
"""
|
|
99
|
+
|
|
100
|
+
existing_volumes: list[str]
|
|
101
|
+
aborted: bool
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
class VolumeCheck:
|
|
105
|
+
"""Check whether known Avatar Docker volumes already exist on the host.
|
|
106
|
+
|
|
107
|
+
If any of ``known_volumes`` are found:
|
|
108
|
+
- In interactive mode: the operator is warned and asked for explicit confirmation.
|
|
109
|
+
- In non-interactive mode: the check fails by default (aborts).
|
|
110
|
+
|
|
111
|
+
Args:
|
|
112
|
+
docker_client: Port for listing Docker volumes.
|
|
113
|
+
input_gatherer: Port for interactive confirmation prompts.
|
|
114
|
+
printer: Port for warning output.
|
|
115
|
+
known_volumes: Volume names to look for. Defaults to
|
|
116
|
+
:data:`AVATAR_KNOWN_VOLUMES` in production.
|
|
117
|
+
interactive: Whether to prompt the operator or fail by default.
|
|
118
|
+
"""
|
|
119
|
+
|
|
120
|
+
def __init__(
|
|
121
|
+
self,
|
|
122
|
+
docker_client: DockerClient,
|
|
123
|
+
input_gatherer: InputGatherer,
|
|
124
|
+
printer: Printer,
|
|
125
|
+
known_volumes: list[str],
|
|
126
|
+
interactive: bool = True,
|
|
127
|
+
) -> None:
|
|
128
|
+
self._docker_client = docker_client
|
|
129
|
+
self._input_gatherer = input_gatherer
|
|
130
|
+
self._printer = printer
|
|
131
|
+
self._known_volumes = known_volumes
|
|
132
|
+
self._interactive = interactive
|
|
133
|
+
|
|
134
|
+
def run(self, app_root: Path) -> VolumeCheckResult: # noqa: ARG002
|
|
135
|
+
"""Detect existing volumes and prompt for confirmation if any are found.
|
|
136
|
+
|
|
137
|
+
Args:
|
|
138
|
+
app_root: Unused by this check; present to satisfy the :class:`Check`
|
|
139
|
+
protocol so all checks share the same ``run`` signature.
|
|
140
|
+
|
|
141
|
+
Returns:
|
|
142
|
+
:class:`VolumeCheckResult` with the found volumes and abort flag.
|
|
143
|
+
"""
|
|
144
|
+
all_volumes = self._docker_client.list_volume_names()
|
|
145
|
+
existing = [v for v in self._known_volumes if v in all_volumes]
|
|
146
|
+
|
|
147
|
+
if not existing:
|
|
148
|
+
return VolumeCheckResult(existing_volumes=[], aborted=False)
|
|
149
|
+
|
|
150
|
+
for name in existing:
|
|
151
|
+
self._printer.print_warning(
|
|
152
|
+
f"Volume '{name}' already exists. "
|
|
153
|
+
"New credentials generated by this install will not match "
|
|
154
|
+
"the existing data in that volume."
|
|
155
|
+
)
|
|
156
|
+
|
|
157
|
+
if not self._interactive:
|
|
158
|
+
# In non-interactive mode, fail by default if volumes are present
|
|
159
|
+
return VolumeCheckResult(existing_volumes=existing, aborted=True)
|
|
160
|
+
|
|
161
|
+
confirmed = self._input_gatherer.prompt_yes_no(
|
|
162
|
+
"Existing volumes were found. Do you still want to proceed with a fresh install?",
|
|
163
|
+
default=False,
|
|
164
|
+
key="preflight.volume_check.confirm",
|
|
165
|
+
)
|
|
166
|
+
|
|
167
|
+
return VolumeCheckResult(existing_volumes=existing, aborted=not confirmed)
|
|
168
|
+
|
|
169
|
+
|
|
170
|
+
# ---------------------------------------------------------------------------
|
|
171
|
+
# DeploymentStateCheck
|
|
172
|
+
# ---------------------------------------------------------------------------
|
|
173
|
+
|
|
174
|
+
|
|
175
|
+
@dataclass
|
|
176
|
+
class DeploymentStateCheckResult:
|
|
177
|
+
"""Result of the existing deployment state pre-flight check.
|
|
178
|
+
|
|
179
|
+
Attributes:
|
|
180
|
+
state: What was found in ``.deployment_states/``:
|
|
181
|
+
- ``"none"`` — directory does not exist; fresh install.
|
|
182
|
+
- ``"in_progress"`` — most recent version is incomplete.
|
|
183
|
+
- ``"completed"`` — at least one completed version exists.
|
|
184
|
+
aborted: ``True`` if the operator chose not to continue.
|
|
185
|
+
resume: ``True`` if the operator chose to resume an in-progress version.
|
|
186
|
+
"""
|
|
187
|
+
|
|
188
|
+
state: Literal["none", "in_progress", "completed"]
|
|
189
|
+
aborted: bool
|
|
190
|
+
resume: bool = False
|
|
191
|
+
|
|
192
|
+
|
|
193
|
+
class DeploymentStateCheck:
|
|
194
|
+
"""Check whether a previous deployment state exists in ``.deployment_states/``.
|
|
195
|
+
|
|
196
|
+
Handles three cases:
|
|
197
|
+
|
|
198
|
+
- **No state** — nothing to do, continue silently.
|
|
199
|
+
- **In-progress** — in interactive mode, offer to resume; in non-interactive mode,
|
|
200
|
+
fail by default.
|
|
201
|
+
- **Completed** — in interactive mode, warn and ask for confirmation;
|
|
202
|
+
in non-interactive mode, fail by default (destructive fresh install requires
|
|
203
|
+
explicit operator confirmation).
|
|
204
|
+
|
|
205
|
+
Args:
|
|
206
|
+
repository: Port for inspecting existing versioned state.
|
|
207
|
+
input_gatherer: Port for interactive prompts.
|
|
208
|
+
printer: Port for warning output.
|
|
209
|
+
interactive: Whether to prompt the operator or fail by default.
|
|
210
|
+
"""
|
|
211
|
+
|
|
212
|
+
def __init__(
|
|
213
|
+
self,
|
|
214
|
+
repository: DeploymentStateRepository,
|
|
215
|
+
input_gatherer: InputGatherer,
|
|
216
|
+
printer: Printer,
|
|
217
|
+
interactive: bool = True,
|
|
218
|
+
) -> None:
|
|
219
|
+
self._repository = repository
|
|
220
|
+
self._input_gatherer = input_gatherer
|
|
221
|
+
self._printer = printer
|
|
222
|
+
self._interactive = interactive
|
|
223
|
+
|
|
224
|
+
def run(self, app_root: Path) -> DeploymentStateCheckResult:
|
|
225
|
+
"""Inspect ``.deployment_states/`` and prompt accordingly.
|
|
226
|
+
|
|
227
|
+
Args:
|
|
228
|
+
app_root: Operator's working directory (the deployment root).
|
|
229
|
+
|
|
230
|
+
Returns:
|
|
231
|
+
:class:`DeploymentStateCheckResult` describing what was found and
|
|
232
|
+
what the operator decided.
|
|
233
|
+
"""
|
|
234
|
+
versions = self._repository.list_versions(app_root)
|
|
235
|
+
|
|
236
|
+
if not versions:
|
|
237
|
+
return DeploymentStateCheckResult(state="none", aborted=False, resume=False)
|
|
238
|
+
|
|
239
|
+
# Check if the most recent version is in-progress.
|
|
240
|
+
latest = versions[-1]
|
|
241
|
+
latest_doc = self._repository.get(app_root, latest)
|
|
242
|
+
|
|
243
|
+
if not latest_doc.is_complete():
|
|
244
|
+
return self._handle_in_progress(latest.label)
|
|
245
|
+
|
|
246
|
+
return self._handle_completed()
|
|
247
|
+
|
|
248
|
+
def _handle_in_progress(self, version_label: str) -> DeploymentStateCheckResult:
|
|
249
|
+
self._printer.print_warning(
|
|
250
|
+
f"An in-progress configuration was found (version {version_label}). "
|
|
251
|
+
"You can resume it or start a completely fresh install."
|
|
252
|
+
)
|
|
253
|
+
|
|
254
|
+
if not self._interactive:
|
|
255
|
+
# In non-interactive mode, fail by default
|
|
256
|
+
return DeploymentStateCheckResult(state="in_progress", aborted=True, resume=False)
|
|
257
|
+
|
|
258
|
+
resume = self._input_gatherer.prompt_yes_no(
|
|
259
|
+
f"Resume the in-progress configuration ({version_label})?",
|
|
260
|
+
default=True,
|
|
261
|
+
key="preflight.deployment_state_check.resume",
|
|
262
|
+
)
|
|
263
|
+
if resume:
|
|
264
|
+
return DeploymentStateCheckResult(state="in_progress", aborted=False, resume=True)
|
|
265
|
+
# Operator declined to resume — abort so they can decide what to do.
|
|
266
|
+
return DeploymentStateCheckResult(state="in_progress", aborted=True, resume=False)
|
|
267
|
+
|
|
268
|
+
def _handle_completed(self) -> DeploymentStateCheckResult:
|
|
269
|
+
self._printer.print_warning(
|
|
270
|
+
"A completed deployment configuration already exists. "
|
|
271
|
+
"Running install will create a completely fresh deployment with "
|
|
272
|
+
"new passwords and secrets — the previous configuration will not be carried forward. "
|
|
273
|
+
"Use 'update' instead to carry values forward from the current deployment."
|
|
274
|
+
)
|
|
275
|
+
|
|
276
|
+
if not self._interactive:
|
|
277
|
+
# In non-interactive mode, fail by default for a destructive fresh install
|
|
278
|
+
return DeploymentStateCheckResult(state="completed", aborted=True, resume=False)
|
|
279
|
+
|
|
280
|
+
confirmed = self._input_gatherer.prompt_yes_no(
|
|
281
|
+
"Do you want to proceed with a fresh install anyway?",
|
|
282
|
+
default=False,
|
|
283
|
+
key="preflight.deployment_state_check.confirm_fresh",
|
|
284
|
+
)
|
|
285
|
+
return DeploymentStateCheckResult(state="completed", aborted=not confirmed, resume=False)
|
|
286
|
+
|
|
287
|
+
|
|
288
|
+
# ---------------------------------------------------------------------------
|
|
289
|
+
# PreflightResult
|
|
290
|
+
# ---------------------------------------------------------------------------
|
|
291
|
+
|
|
292
|
+
|
|
293
|
+
@dataclass
|
|
294
|
+
class PreflightResult:
|
|
295
|
+
"""Aggregated result of all pre-flight checks.
|
|
296
|
+
|
|
297
|
+
``results`` is ordered — each entry corresponds to a check in the same
|
|
298
|
+
position as the list passed to :class:`PreflightCheck`. If the checker
|
|
299
|
+
short-circuited, later entries will be absent.
|
|
300
|
+
|
|
301
|
+
Args:
|
|
302
|
+
results: Ordered list of individual :class:`CheckResult` objects.
|
|
303
|
+
"""
|
|
304
|
+
|
|
305
|
+
results: list[CheckResult] = field(default_factory=list)
|
|
306
|
+
|
|
307
|
+
def aborted(self) -> bool:
|
|
308
|
+
"""Return ``True`` if any check requested an abort."""
|
|
309
|
+
return any(r.aborted for r in self.results)
|
|
310
|
+
|
|
311
|
+
def resume(self) -> bool:
|
|
312
|
+
"""Return ``True`` if the operator chose to resume an in-progress state.
|
|
313
|
+
|
|
314
|
+
Scans ``results`` for a :class:`DeploymentStateCheckResult` and returns
|
|
315
|
+
its ``resume`` flag. Returns ``False`` if no such result is present.
|
|
316
|
+
"""
|
|
317
|
+
for result in self.results:
|
|
318
|
+
if isinstance(result, DeploymentStateCheckResult):
|
|
319
|
+
return result.resume
|
|
320
|
+
return False
|
|
321
|
+
|
|
322
|
+
|
|
323
|
+
# ---------------------------------------------------------------------------
|
|
324
|
+
# PreflightCheck
|
|
325
|
+
# ---------------------------------------------------------------------------
|
|
326
|
+
|
|
327
|
+
|
|
328
|
+
class PreflightCheck:
|
|
329
|
+
"""Run an ordered list of checks, short-circuiting on first abort.
|
|
330
|
+
|
|
331
|
+
Collects each check's result into a :class:`PreflightResult`. If a check
|
|
332
|
+
returns ``aborted=True`` the remaining checks are skipped immediately.
|
|
333
|
+
|
|
334
|
+
This class is injected into :class:`~application.install_command.InstallCommand`
|
|
335
|
+
and can be given any list of :class:`Check` implementations, making it
|
|
336
|
+
reusable for future commands (``update``, etc.) that need their own guard
|
|
337
|
+
checks.
|
|
338
|
+
|
|
339
|
+
Args:
|
|
340
|
+
checks: Ordered list of check instances to run.
|
|
341
|
+
"""
|
|
342
|
+
|
|
343
|
+
def __init__(self, checks: list[Check]) -> None:
|
|
344
|
+
self._checks = checks
|
|
345
|
+
|
|
346
|
+
def run(self, app_root: Path) -> PreflightResult:
|
|
347
|
+
"""Execute all checks in order, returning an aggregated result.
|
|
348
|
+
|
|
349
|
+
Args:
|
|
350
|
+
app_root: Operator's working directory forwarded to each check.
|
|
351
|
+
|
|
352
|
+
Returns:
|
|
353
|
+
:class:`PreflightResult` containing all executed check results.
|
|
354
|
+
If the first check aborts, subsequent check results are not included.
|
|
355
|
+
"""
|
|
356
|
+
collected: list[CheckResult] = []
|
|
357
|
+
for check in self._checks:
|
|
358
|
+
result = check.run(app_root)
|
|
359
|
+
collected.append(result)
|
|
360
|
+
if result.aborted:
|
|
361
|
+
break # short-circuit
|
|
362
|
+
return PreflightResult(results=collected)
|