RFC: Cleaning up installer hooks

The following is a list of hooks currently in the installer, the scenario that currently exist in and proposals for each hook going forward.

Hook Based Option Description Scenario Proposal
reset-foreman-db Clear Foreman database Foreman Merge with --reset and rename to --reset-data
detailed-exitcodes Foreman Keep
lock-package-versions lock packages through yum via foreman-maintain Katello Move to Foreman scenario
reset Clear Katello backends and database Katello Merge with --reset and rename to --reset-data
clear-pulp-content Clears pulp content from disk Katello Keep for Katello
clear-puppet-environments Katello Keep for Katello
tuning Katello Move to Foreman scenario
disable-system-checks Katello Move to Foreman scenario
force-upgrade-steps Katello Drop
certs-update-server Katello Keep for Katello
certs-update-server-ca Katello Keep for Katello
certs-update-all Katello Keep for Katello
certs-reset Katello Keep for Katello
certs-skip-check Katello Keep for Katello
upgrade-mongo-storage-engine Katello Keep for Katello
upgrade Katello Drop
disable-resolve-mismatches Katello Drop
1 Like

I never liked the overlap with --skip-checks-i-know-better that comes from kafo itself. Can we merge this as well?

At a later stage I think certs also needs some love and we can potentially remove the need for the parameters but your list is a good short term plan.

IIRC we introduced disable-system-checks because we had to put some checks into the hooks and the skip-checks-i-know-better handled only those things put into actual checks/. That leans me towards dropping checks/ given they lack all of the contextual information that hooks/ have.

I tend to agree that checks are limited and hooks provide more context that’s useful. However, it’s still a bad UX to have two parameters for pretty much the same thing. In a hook you can also check if the --skip-checks-i-know-better parameter was supplied so that’s one potential implementation. I’d just like to converge on one.

We can also think about a better implementation where the parameter can accept arguments to skip individual checks. With this we can skip the sizing check in our CI without disabling all others to get better coverage.

Fair. I think enough users know about disable-system-checks that I would opt for removing skip-checks-i-know-better in favor of disable-system-checks. I’d also suggest we drop checks/ in favor of a new hook for checks.