Aptly package install fails 1st time Puppet runs
Closed this issue · 2 comments
I use this module in my application and every time I ran Puppet for the 1st time, it fails to install aptly. Is this a know-issue or it's only happening for me?
Here is a snippet from the output during the Puppet run:
Notice: /Stage[main]/Aptly/Apt::Source[aptly]/Apt::Key[Add key: B6140515643C2AE155596690E083A3782A194991 from Apt::Source aptly]/Apt_key[Add key: B6140515643C2AE155596690E083A3782A194991 from Apt::Source aptly]/ensure: created
Notice: /Stage[main]/Aptly/Apt::Source[aptly]/Apt::Setting[list-aptly]/File[/etc/apt/sources.list.d/aptly.list]/ensure: created
Info: /Stage[main]/Aptly/Apt::Source[aptly]/Apt::Setting[list-aptly]/File[/etc/apt/sources.list.d/aptly.list]: Scheduling refresh of Class[Apt::Update]
Error: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold install aptly' returned 100: Reading package lists...
Building dependency tree...
Reading state information...
E: Unable to locate package aptly
Error: /Stage[main]/Aptly/Package[aptly]/ensure: change from purged to present failed: Execution of '/usr/bin/apt-get -q -y -o DPkg::Options::=--force-confold install aptly' returned 100: Reading package lists...
Building dependency tree...
Reading state information...
E: Unable to locate package aptly
Thanks!
Hi @roccatgaming, thanks for opening this issue. I think this is a problem with a module.
On the first Puppet run, we add an apt::source
resource for http://repo.aptly.info
. In the output above you can see this runs Scheduling refresh of Class[Apt::Update]
which means that later in the Puppet run apt-get update
will run which will tell your system where to install Aptly from.
However apt-get install aptly
runs before the apt-get update
which is why it breaks.
We think that the pull request above will resolve the problem so we're going to close this issue. If you still experience the failure please feel free to reopen it.
Thank you for raising it.