-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Spawn reactive runner #8
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good to me
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Comments to support the PR review.
# Conflicts: # pyproject.toml
Test coverage for d72fa72
Static code analysis report
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Minor comment on formatting of a code comment.
Applicable spec: ISD-116
Overview
Spawn a reactive runner after consuming a message from the queue.
This PR only adds the logic of spawning a reactive runner (and cleaning up at the next reconciliation).
Subsequent PRs are planned to include label validation and running the script under a separate user.
Successful integration test run on github-runner-operator: https://github.com/canonical/github-runner-operator/actions/runs/10920989028/job/30314702314
Rationale
In order to implement reactive scheduling, we need to spawn runners.
Module Changes
(skipped the
github_runner_manager
package name prefix)openstack_cloud.openstack_runner_manager
: Move constructor args into a dataclass.reactive.consumer
: Implement spawning and interaction with message queue and checking the status of the job.reactive.runner
: Rewrite script to accept new configuration.reactive.runner_manager
: Call script with new interface.github_client
: Add method to call https://docs.github.com/en/rest/actions/workflow-jobs?apiVersion=2022-11-28#get-a-job-for-a-workflow-run.New modules:
reactive.types_
: Contains the configuration object that is passed to the script to spawn a runner.Library/Dependency Changes
Checklist
src-docs
urgent
,trivial
,complex
)pyproject.toml
is incremented