Skip to content

Conversation

@Dany9966
Copy link
Contributor

The new auto_deploy execution option will be used to kick off pending deployments, which will start running when the transfer execution finishes successfully. These automatic deployments are managed by a new service, called coriolis-deployer-manager, which picks up pending deployments and manages their lifecycle.

Default deployment options have also been added to the transfer information, like "clone_disks", and "skip_os_morphing", in order for the pending deployments to be able to launch right after the execution starts, using these default options.

This commit implements core logic for auto deployment feature, which allows
deployer executions to launch deployments that will wait and automatically
start after the transfer execution is completed. This is done by launching
a separate greenthread for each deployer execution.
Exposes the auto deployment feature as `auto_deploy` option in the transfer
execution body.
Adds default deployment options to transfers, which will be used for
auto-deployments.
Adds ability to transfer schedules to start a deployer execution
Adds new execution status for deployments that wait for deployers' completion.
Adds executable service entry for the deployer manager, which will
manage the lifecycle and automation of the deployments launched
by deployer executions, using the `auto_deploy` transfer execution
option.
The auto deployments feature required creation of deployments
without executions, making it unsafe to presume the deployment
will have an execution at any time. This patch fixes this by
checking that the deployment has an execution, before trying
to access it for operations like deployment deletion or
cancellation.
@Dany9966 Dany9966 force-pushed the auto-deployments branch 2 times, most recently from d272c4c to f8e536f Compare February 27, 2025 15:42
Logs exception details in case an exception occurs in
`_check_deployer_status`. It also logs the message as `ERROR`
severity.
This patch makes sure that only auto deployments are started in
`PENDING` state. All manually launched deployments should start
with `UNEXECUTED` status, as the deployment execution gets created
right after. This will disallow the deployer manager to pick up
manual deployments.
Fixes the `shutdown_instances` keyword argument name.
Fixes an issue where a transfer execution schedule with
`auto_deploy` enabled will create a deployment with user and
project ID missing from the request context. This patch applies
the transfer user and project IDs to the deployment, in case they
are missing from the request context.
Adds logic to validate manually launched deployments before creating
the deployment, while also validating auto deployments' inputs
before creating the deployment execution.
…ution

When a schedule with `auto_deploy` enabled triggers the transfer and pending
deployment using a user trust that's registered in the schedule information.

After a deployment finishes, the trust_id is always deleted, making it
impossible for the user to delete an auto_deploy-enabled transfer schedule.

This patch makes sure that a transfer schedule can be deleted, even though
its trust_id fails to delete.
@Dany9966 Dany9966 merged commit 6f3e392 into cloudbase:master Mar 5, 2025
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant