Katello / katello-client-bootstrap

Bootstrap Script for migrating systems to Foreman & Katello
GNU General Public License v2.0
52 stars 63 forks source link

Capsule migration option, take 2 #227

Closed wzzrd closed 6 years ago

wzzrd commented 6 years ago

So after a long pause, here's attempt two to bring in a capsule migration option into bootstrap.py.

Because the change is fairly large, here's the breakdown, to start with the nitty-gritty stuff:

Remarks:

Sample usage is provided in README.md. Tested on RHEL6 and RHEL7 w/ Satellite 6.2.12. RHEL5 untested, but I'm not using any functionality in Python that wasn't available on Python 2.4 (I think).

wzzrd commented 6 years ago

Soooo..... the bare excepts that Travis still complains about have been in there for months and have your prints all over them, @evgeni ;)

Not sure what to do about those...

evgeni commented 6 years ago

@wzzrd ah, this is new in flake8 3.5.0. Let's see how we can fix that.

wzzrd commented 6 years ago
@evgeni, @sideangelside, so, any comments on how to move this forward, i.e. get this merged?
wzzrd commented 6 years ago

As for the Capsule / Proxy discussion: I'm not against naming everything by the upstream names, but the problem is that there is a million places where that is not the case right now.

To be honest, looking at get_api_port(), that will only work on Satellite or Capsule servers, because it relies on parsing/etc/rhsm/rhsm.conf. That file might not even exist on pure upstream Foreman / Foreman Proxy, as I understand it. I'm not saying that is right, I'm just saying this issue needs a closer look.

wzzrd commented 6 years ago

Please review code, but wait with potential merge until I do a final functional that I cannot do here.

wzzrd commented 6 years ago

@evgeni ping

wzzrd commented 6 years ago

Test done w/ RHEL7 on Satellite 6.2.12 machine and ditto Capsule. One last change incorporated, works fine otherwise: 6e8d9bee966a5dbf75463da9ea24c82a9e5f0661

evgeni commented 6 years ago

/etc/rhsm/rhsm.conf exists on Katello clients, which is good enough for us :)

wzzrd commented 6 years ago

@evgeni @sideangleside are yall waiting for me to 's/capsule/smart_proxy/g' or is there something else?

wzzrd commented 6 years ago

@evgeni I've manually rebased on current master this morning because there were some conflicts

evgeni commented 6 years ago

@wzzrd puppet4 support and sed-fixes are at https://github.com/evgeni/katello-client-bootstrap/tree/capsule-migration-option-new, feel free to pull these in

wzzrd commented 6 years ago

Pulled in latest master and changes from your fork, @evgeni

evgeni commented 6 years ago

Thanks @wzzrd! I think if we update the README to say Katello and not Satellite and give the new Capsule a example.com domain as with the rest of the examples, this is good to go.

@sideangleside you also happy with that?

wzzrd commented 6 years ago

Done.

sideangleside commented 6 years ago

I finally got time to review this. No issues to report from me. Other than squashing the commits, we can merge this PR. Thanks for the pretty big feature @wzzrd

wzzrd commented 6 years ago

Squashed and pushed @sideangleside @evgeni