Skip to content
This repository has been archived by the owner on Feb 7, 2023. It is now read-only.

Move subscription-manager auto-attach parameter in subscription file #250

Merged
merged 1 commit into from
Sep 26, 2017

Conversation

guillaumevincent
Copy link
Contributor

subscription_data.csv.sample got an extra parameter.
We can use this extra parameter to subscribe with activationkey for example.

extra,--activationkey='...' --org='...'

If we do so, roles/redhat_subscription/tasks/main.yml:46 raise an error:

"Error: Activation keys cannot be used with --auto-attach."

Move --auto-attach in subscription file sample.
Remove --force because extra param is already set

This PR fixes #249

subscription_data.csv.sample got an extra parameter.
We can use this extra parameter to subscribe with activationkey for example.

extra,--activationkey='...' --org='...'

If we do so, roles/redhat_subscription/tasks/main.yml:46 raise an error:

    "Error: Activation keys cannot be used with --auto-attach."

Move --auto-attach in subscription file sample.
Remove --force because extra param is already set

This PR fixes projectatomic#249
@rh-atomic-bot
Copy link

Can one of the admins verify this patch?
I understand the following commands:

  • bot, add author to whitelist
  • bot, test pull request
  • bot, test pull request once

@miabbott
Copy link
Collaborator

@guillaumevincent If we remove the --auto-attach flag from the extra parameters, shouldn't we also have a subscription-manager attach command elsewhere in the role?

@guillaumevincent
Copy link
Contributor Author

@miabbott my PR added the --auto-attach flag into the extra parameters. So I don't understand the question. It's the opposite.

I just allow users to remove it if like me they want to subscribe with activation key.

@guillaumevincent
Copy link
Contributor Author

It's not visible in the pull request but extra parameters are called at the end of the command:

{{ lookup('csvfile', 'extra file={} default='' delimiter=,'.format(subscription_file)) }}

@miabbott
Copy link
Collaborator

@guillaumevincent My mistake; I don't know how I got confused like that. ¯_(ツ)_/¯

I'll have the bot run tests against this PR.

@miabbott
Copy link
Collaborator

bot, add author to whitelist

@guillaumevincent
Copy link
Contributor Author

It looks like 3 builds failed because of coreos/rpm-ostree#233

Register with subscription-manager is ignored on Centos and Fedora. Only used on RHEL

@miabbott
Copy link
Collaborator

@guillaumevincent Unfortunately, our method of testing PRs can also uncover issues on the platforms we are testing, as we are seeing here:

  • The centos/7/atomic test failed because when doing rpm-ostree install httpd, it pulls in centos-logos which wants to install /boot/grub/splash.xpm.gz. This is not currently supported in the version of rpm-ostree included in CentOS AH. See pkglayering: support packages installing into /boot coreos/rpm-ostree#853 which shows that there was a fix made only 18 days ago.

  • The fedora/25/atomic failure is due to an case of a file with the unlabeled_t SELinux context. Additionally, we are phasing out testing PRs against Fedora 25, so this checkpoint will be gone in the future.

  • The fedora/26/atomic failure appears to be another SELinux issue, where the test is claiming that an AVC denial was found in the journal. I don't think is is related to this PR, so we can waive this failure.

I'll put it on my todo list to checkout this PR locally and run some of my own tests just to be certain, but I'm very confident this PR will be merged in the next day or two.

@guillaumevincent
Copy link
Contributor Author

Thanks for the update @miabbott

@miabbott
Copy link
Collaborator

@guillaumevincent I ran this PR locally against RHEL, Fedora 26, and CentOS AH Continuous without trouble. Thanks for the patience!

@miabbott miabbott merged commit b386644 into projectatomic:master Sep 26, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Missing org_id and activationkey lookup for redhat subscription
4 participants