-
Notifications
You must be signed in to change notification settings - Fork 200
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Pulpcore to 3.39 #1725
Update Pulpcore to 3.39 #1725
Conversation
0603685
to
e3a16bb
Compare
I've also made it so the pulpcore module is not installed unless the pulpcore version is between 3.16 and 3.39. I'm not 100% certain if I should add the second conditional like I did. |
e3a16bb
to
8afe739
Compare
# https://github.com/ansible/ansible/issues/56504 | ||
# https://github.com/ansible/ansible/issues/64852 | ||
args: | ||
creates: /etc/dnf/modules.d/pulpcore.module |
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.
I don't think this is right. The file will already be there if it is enabled and instead it will actually skip this step if it's enabled (which is true for upgrades).
Just for background:
# dnf module enable pulpcore:el8
# ls /etc/dnf/modules.d
pulpcore.module python39.module
# dnf module disable pulpcore
# ls /etc/dnf/modules.d
pulpcore.module python39.module
# cat /etc/dnf/modules.d/pulpcore.module
[pulpcore]
name=pulpcore
stream=
profiles=
state=disabled
Note that the enable part also enabled python39 but disable doesn't disable python. It looks like ansible-core has rebased to python3.11 (al least in CentOS Stream 8), but worth considering in the release notes.
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.
@evgeni any thoughts on using this for idempotency?
- name: 'Disable pulpcore:el8 module'
command: dnf module disable -y pulpcore:el8
args:
removes: /etc/dnf/modules.d/pulpcore.module
- name: Delete pulpcore module
file:
path: /etc/dnf/modules.d/pulpcore.module
state: absent
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.
This looks reasonable. The removes
on the disable command is a "lie", but then you fix it up and things should be fine.
OTOH, we could also just remove the file, that's the only thing that carries the info about the module state.
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.
I went with remove only and updated the PR
8afe739
to
deabede
Compare
Related: