Description of problem: A userdata script that includes a package module will fail during deployment in Fedora-Cloud-Base-25 images (Found on image from April 26 2017). It was found that cloudinit/distros/rhel.py is patched in Fedora, and the patch includes python os.path calls without importing os, resulting in a NameError during execution. The upstream cloud-init 0.7.9 package does not exhibit this behavior. Version-Release number of selected component (if applicable): cloud-init 0.7.9-4.fc25 How reproducible: 100% Steps to Reproduce: 1. Produce cloud-init script with a 'packages' section to install some packages 2. Deploy new instance and execute cloud-init with packages section 3. Observe cloud-init output/logs, where package module fails with exception Actual results: Packages are not installed, cloud-init fails with exception Expected results: Packages listed in userdata script are installed on the target machine Additional info: It appears that the patch was added to the release notes for cloud-init-0.7.6-3 on Feb 19 2015 by Garrett Holmstrom
The Fedora patch should probably be replaced by upstream commit a3daf184, which solves the same problem but uses cloudinit.util.which rather than os.path.
https://git.launchpad.net/cloud-init/commit/?id=a3daf184fd47dede8d91588281437453bd38fc1c
I tested out Lars's suggestion in a COPR, and it works as expected. The spec file changes are in the COPR instructions. https://copr.fedorainfracloud.org/coprs/carlgeorge/cloud-init-rhbz1447708/
cloud-init-0.7.9-6.fc26 has been submitted as an update to Fedora 26. https://bodhi.fedoraproject.org/updates/FEDORA-2017-1912218b0c
Proposed as a Freeze Exception for 26-final by Fedora user gholms using the blocker tracking app because: The currently-stable version of cloud-init is not able to install packages correctly after some upstream changes that broke one of our patches. A fix is in updates-testing, but if it doesn't go stable before release it won't make it into the F26 base cloud image.
cloud-init-0.7.9-6.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-faae58b0d0
cloud-init-0.7.9-6.fc26 has been pushed to the Fedora 26 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-1912218b0c
I have tested the cloud-init-0.7.9-6.fc25 package from updates-testing with a simple cloud-config file containing a single package. The "package_update_upgrade_install" module ran successfully and installed the package on F25.
I made a couple of images to test the new version of cloud-init in f26 https://dustymabe.fedorapeople.org/atomic-host-cloud-init-0.7.9-6.qcow2 https://dustymabe.fedorapeople.org/cloud-base-cloud-init-0.7.9-6.qcow2 Please test it out and give karma to: https://bodhi.fedoraproject.org/updates/FEDORA-2017-1912218b0c
Thanks for the images Dusty, testing and adding karma
cloud-init-0.7.9-6.fc26 has been pushed to the Fedora 26 stable repository. If problems still persist, please make note of it in this bug report.
For the record, though in fact the update has gone stable already: Discussed at 2017-06-26 freeze exception review meeting: https://meetbot-raw.fedoraproject.org/fedora-blocker-review/2017-06-26/f26-blocker-review.2017-06-26-16.03.html . Accepted as a freeze exception issue on the basis this obviously breaks a feature of the Cloud images that cannot be entirely fixed with a post-release update.
cloud-init-0.7.9-7.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2017-faae58b0d0
cloud-init-0.7.9-7.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-faae58b0d0
This has been fixed for 26, so dropping the 26-only FE stuff.
cloud-init-0.7.9-9.fc25 has been submitted as an update to Fedora 25. https://bodhi.fedoraproject.org/updates/FEDORA-2017-5507234819
cloud-init-0.7.9-9.fc25 has been pushed to the Fedora 25 testing repository. If problems still persist, please make note of it in this bug report. See https://fedoraproject.org/wiki/QA:Updates_Testing for instructions on how to install test updates. You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2017-5507234819
This message is a reminder that Fedora 25 is nearing its end of life. Approximately 4 (four) weeks from now Fedora will stop maintaining and issuing updates for Fedora 25. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '25'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 25 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete.
Fedora 25 changed to end-of-life (EOL) status on 2017-12-12. Fedora 25 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed.