Skip to content

Conversation

@ArangoGutierrez
Copy link
Collaborator

Rename hook functions to describe their actions rather than when they run. Add documentation comments for clarity. No API changes.

Rename hook functions to describe their actions rather than when they
run. Add documentation comments for clarity. No API changes.

Signed-off-by: Carlos Eduardo Arango Gutierrez <[email protected]>
@ArangoGutierrez ArangoGutierrez self-assigned this Nov 10, 2025
@ArangoGutierrez ArangoGutierrez changed the title use functional names for hook bash functions Use functional names for hook bash functions Nov 10, 2025
# stop-services-for-mode stops all GPU-dependent services (K8s workloads
# and driver services) before applying MIG mode changes that require a
# GPU reset.
function stop-services-for-mode() {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of duplicating the stop_k8s_services and stop_k8s_pods across stop-services-for-mode and stop-services-for-config, should we invoke stop_driver_services directly as a hook from pre-apply-mode and invoke stop-services from both apply-mode and pre-apply-config?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check : Refactor: move service stop orchestration to hook configuration level , added as an additional commit. If you approve, I'lll edit the PR description

Replace stop-services-for-mode and stop-services-for-config with a single stop-services function. Build the complete stop sequence in hooks-default.yaml by invoking stop-services and stop_driver_services separately.
This removes

Signed-off-by: Carlos Eduardo Arango Gutierrez <[email protected]>
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.

2 participants