fixes #19622 - adds error if backup directory missing #450
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.
Other than one comment, works well
katello/katello-restore
Outdated
`tar --selinux --overwrite --listed-incremental=/dev/null -xzf config_files.tar.gz -C /` | ||
`foreman-installer --scenario katello --reset` | ||
run_cmd "tar --selinux --overwrite --listed-incremental=/dev/null -xzf config_files.tar.gz -C /" | ||
run_cmd("foreman-installer --scenario katello --reset", [0,6]) |
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.
Since foreman-installer --reset
has a y/n confirmation that will stall out this script, I had to pipe yes into the command:
run_cmd("yes | foreman-installer --scenario katello --reset", [0,6])
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.
Since this is actually working upstream on the latest snaps, I'd like to merge this one, and hopefully get a flag written to the foreman-installer to bypass this issue versus having to temporarily pipe yes. Are you okay to ACK or do you really want those changes in now?
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.
@cfouant By latest snaps do you mean 3.4?
Since this command is currently broken in master, my thought is to do this to avoid any issues:
- use "yes" workaround in this PR
- fix in foreman-installer with -y flag or similar
- remove "yes" workaround once foreman-installer flag can be used
@johnpmitsch could you okay the requested changes so this PR goes green? |
1143f23
to
2152227
Compare
katello/katello-restore
Outdated
installer = "yes | foreman-installer -v --reset" | ||
if @foreman_proxy_content | ||
run_cmd("tar --selinux --overwrite --listed-incremental=/dev/null -xzf config_files.tar.gz -C /") | ||
installer = "yes | foreman-installer -v --reset" if @foreman_proxy_content |
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 like this if @foreman_proxy_content
should be moved to the next line
fatal: [192.168.121.46]: FAILED! => {"changed": true, "cmd": ["/katello-packaging/katello/katello-restore", "-y", "-d", "/backup/katello-backup-20170627192411"], "delta": "0:00:00.043689", "end": "2017-06-27 19:26:41.618141", "failed": true, "rc": 1, "start": "2017-06-27 19:26:41.574452", "stderr": "/katello-packaging/katello/katello-restore:67: warning: else without rescue is useless\n/katello-packaging/katello/katello-restore:74: syntax error, unexpected keyword_end, expecting end-of-input", "stdout": "", "stdout_lines": [], "warnings": []}
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.
ah, yes. rebasing--
No description provided.