-
Notifications
You must be signed in to change notification settings - Fork 898
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
Mark workers associated with failed systemd units as stopped #23182
Mark workers associated with failed systemd units as stopped #23182
Conversation
If a systemd unit is failed but there is still a miq_worker record associated with it we should mark that worker record as stopped. This will then be cleaned up by the subsequent `clean_worker_records` method.
b1e30ad
to
728e223
Compare
Checked commits agrare/manageiq@2906f85~...728e223 with ruby 3.1.5, rubocop 1.56.3, haml-lint 0.51.0, and yamllint |
Okay I ran a live test on a master appliance build with this applied and I enable the embedded_terraform role first then set the container_image later and confirmed the failed workers are marked stopped and later deleted and then after the container_image setting is set properly the next time the worker starts up it pulls the correct image. Taking out of WIP |
Backported to
|
…topped Mark workers associated with failed systemd units as stopped (cherry picked from commit de72e9e)
If we start a systemd unit and it fails this can leave the miq_worker record associated with it in "creating" without ever being cleaned up.
When we stop and cleanup any failed systemd units we should also mark any associated miq-worker records as stopped so that they can be cleaned up by the
clean_worker_records
method.TODO
Fixes ManageIQ/manageiq-providers-embedded_terraform#59