-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
opkg module: allow installing a package in a certain version #5688
opkg module: allow installing a package in a certain version #5688
Conversation
f8d7fab
to
3b06754
Compare
3b06754
to
787796c
Compare
Docs Build 📝Thank you for contribution!✨ This PR has been merged and your docs changes will be incorporated when they are next published. |
This comment was marked as outdated.
This comment was marked as outdated.
308a181
to
1eeeaca
Compare
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.
Thanks for your contribution! I've added some first comments.
changelogs/fragments/5688-opkg-module-install-certain-version.yml
Outdated
Show resolved
Hide resolved
1eeeaca
to
5bd3977
Compare
@felixfontein I also noticed that there was a bug that parameter |
Could you please move the bugfix to a new PR so we can backport it also to stable-5? Thanks. |
7beae34
to
ccdd57b
Compare
Sure. See PR #5705 |
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 good to me (looking at the code; I cannot test it). Now there is a conflict that needs to be resolved though (please rebase).
example: - name: Install foo in version 1.2 community.general.opkg: name: foo=1.2 state: present Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com>
Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com>
ccdd57b
to
5232803
Compare
Rebased in 5232803 Also I executed a test with python3.10 and opkg 0.4.2 on NI Linux Real-Time 8.8: opkg-tests.yml: - name: "opkg tests"
gather_facts: no
tasks:
- name: "opkg remove (1)"
community.general.opkg:
name: "tmux"
state: "absent"
- name: "opkg remove (2)"
community.general.opkg:
name: "tmux"
state: "absent"
- name: "opkg install (1)"
community.general.opkg:
name: "tmux"
state: "present"
- name: "opkg install (2)"
community.general.opkg:
name: "tmux"
state: "present"
- name: "install --force-reinstall"
community.general.opkg:
name: "tmux"
state: "present"
force: "reinstall"
- name: "opkg remove (3)"
community.general.opkg:
name: "tmux"
state: "absent"
- name: "opkg install with version"
community.general.opkg:
name: "tmux=2.6-r0.18"
state: "present"
- name: "opkg install with incorrect version"
community.general.opkg:
name: "tmux=2.6"
state: "present" $ ansible-playbook opkg-tests.yml PLAY [opkg tests] ************************************************************************************************************************** TASK [opkg remove (1)] ************************************************************************************************************************** TASK [opkg remove (2)] ************************************************************************************************************************** TASK [opkg install (1)] ************************************************************************************************************************** TASK [opkg install (2)] ************************************************************************************************************************** TASK [install --force-reinstall] ************************************************************************************************************************** TASK [opkg remove (3)] ************************************************************************************************************************** TASK [opkg install with version] ************************************************************************************************************************** TASK [opkg install with incorrect version] ************************************************************************************************************************** PLAY RECAP ************************************************************************************************************************** |
Thanks for testing it! :) I'll keep this open a few more days and will then merge it if nobody objects until then. |
Merging so that #5718 can rebase and advance. |
Backport to stable-6: 💚 backport PR created✅ Backport PR branch: Backported as #5724 🤖 @patchback |
* opkg: allow installing a package in a certain version example: - name: Install foo in version 1.2 community.general.opkg: name: foo=1.2 state: present Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com> * opkg: use list for passing arguments to run_command Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com> Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com> (cherry picked from commit b3485b8)
@joergho thanks for contributing this! |
…a package in a certain version (#5724) opkg module: allow installing a package in a certain version (#5688) * opkg: allow installing a package in a certain version example: - name: Install foo in version 1.2 community.general.opkg: name: foo=1.2 state: present Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com> * opkg: use list for passing arguments to run_command Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com> Signed-off-by: Joerg Hofrichter <joerg.hofrichter@ni.com> (cherry picked from commit b3485b8) Co-authored-by: joergho <48011876+joergho@users.noreply.github.com>
SUMMARY
This extends the community.general.opkg module. It additionally allows to install a package in a certain version.
Tested with opkg 0.4.2 on NI Linux Real-Time 8.8
ISSUE TYPE
COMPONENT NAME
community.general.opkg module
ADDITIONAL INFORMATION
opkg module: allow NAME=VERSION syntax to install a package in a certain version
example: