Description of problem: When trying to set Satellite admin password using the satellite installer command the password is not getting updated. Using the same old password. Version-Release number of selected component (if applicable): >> Satellite 6.4 Beta. How reproducible: >> We can run the satellite-installer command along with the password option. Steps to Reproduce: >> On the Satellite terminal. # satellite-installer -S satellite --foreman-admin-username admin --foreman-admin-password abc123 Actual results: >> Installer completes successfully. Expected results: >> Foreman admin password must be updated. Additional info: NA
Is this first run of the installer or consecutive run? Note that the installer does not add new admin account with new password if the admin accoun already exist after first installer run. That would be probably even less expected, imagine admin changes the password after installation, installer rerun would change it back to original one, e.g. during upgrade. IMHO this is not a bug? Today the installer help says this --foreman-admin-password Password of the initial admin user, default is randomly generated (current: "changeme") --foreman-admin-username Username for the initial admin user (current: "admin") Should we rephrase so that's clearer?
I understand this causes a confusion. I'd suggest adding more explanatory comment to user and password field that this only applies on empty database. They would be only effective with --reset option which I would not recommend to use as it clears all data! There were two concerns raised > First: If installer run with only option '--foreman-admin-password' then it > should change, > or should shows a warning if not requires to run second time instead of > installer complete eveytime successfully. Given the way how installer works - remembering values in answer file and always applying the full configuration, this is not something these options could provide. We could add add new options, e.g. --reset-admin-password but I don't think this is installer domain. If the use case is resetting forgotten password, I think we should add such functionality to foreman-maintain. > Second, Currently installer is running and completing successfully without any > error while passing the new password and updating unnecessary password in > 'satellite-answers.yaml' even same does not work for admin user: This is because the installer successfully changed the default credentials that would be applied during empty DB seeding. This does not happen during second run, unless the DB has been wiped out. So, would rephrasing the help text solve this if it sounded more like "Password of the initial admin user, default is randomly generated (current: "changeme"). This is only applicable for new installations, later changes are not reflected unless the database is reset."
(In reply to Marek Hulan from comment #4) > I understand this causes a confusion. I'd suggest adding more explanatory > comment to user and password field that this only applies on empty database. > They would be only effective with --reset option which I would not recommend > to use as it clears all data! > > There were two concerns raised > > > First: If installer run with only option '--foreman-admin-password' then it > > should change, > > > or should shows a warning if not requires to run second time instead of > > installer complete eveytime successfully. > > Given the way how installer works - remembering values in answer file and > always applying the full configuration, this is not something these options > could provide. We could add add new options, e.g. --reset-admin-password but > I don't think this is installer domain. If the use case is resetting > forgotten password, I think we should add such functionality to > foreman-maintain. > > > Second, Currently installer is running and completing successfully without any > > error while passing the new password and updating unnecessary password in > > 'satellite-answers.yaml' even same does not work for admin user: > > This is because the installer successfully changed the default credentials > that would be applied during empty DB seeding. This does not happen during > second run, unless the DB has been wiped out. > > So, would rephrasing the help text solve this if it sounded more like > "Password of the initial admin user, default is randomly generated (current: > "changeme"). This is only applicable for new installations, later changes > are not reflected unless the database is reset." Thanks, As per my understanding below would help: -> in satellite-installer - adding more explanatory comment to user and password field. -> add reset password functionality to foreman-maintain.
Moving this bug to POST for triage into Satellite 6 since the upstream issue https://projects.theforeman.org/issues/25170 has been resolved.
Verified Verified on: Satellite 6.6.0 snap 7 This bug is not valid anymore as the options --foreman-admin-username admin --foreman-admin-password are now replaced with --foreman-initial-admin-username and --foreman-initial-admin-password
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHSA-2019:3172