-
Notifications
You must be signed in to change notification settings - Fork 224
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
Installation on ubuntu 18.04 fails #37
Comments
Hi, That's interesting. It passes the tests for Ubuntu 18.04 on https://travis-ci.org/nickjj/ansible-docker/jobs/446816674 and I've installed this role a lot of times on DigitalOcean using 18.04. Also, it looks like gnupg2 exists on https://packages.ubuntu.com/bionic/gnupg2. Have you ran apt-get update on your host at least once? This should be a part of any Ansible bootstrap strategy which is why this role doesn't run apt-get update on its own. |
That did the trick, thanks a lot and sorry for bothering! |
I'm having the same problem, I am not sure why gnupg2 is not present in the current repolist (even after apt-get update -y) What I have did before running the play:
If you need anything else from me to help you debug this problem I'll try and provide info. apt-cache search gnupg2; cat /etc/*-release; apt-cache policy
devscripts - scripts to make the life of a Debian Package maintainer easier
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=18.04
DISTRIB_CODENAME=bionic
DISTRIB_DESCRIPTION="Ubuntu 18.04.1 LTS"
NAME="Ubuntu"
VERSION="18.04.1 LTS (Bionic Beaver)"
ID=ubuntu
ID_LIKE=debian
PRETTY_NAME="Ubuntu 18.04.1 LTS"
VERSION_ID="18.04"
HOME_URL="https://www.ubuntu.com/"
SUPPORT_URL="https://help.ubuntu.com/"
BUG_REPORT_URL="https://bugs.launchpad.net/ubuntu/"
PRIVACY_POLICY_URL="https://www.ubuntu.com/legal/terms-and-policies/privacy-policy"
VERSION_CODENAME=bionic
UBUNTU_CODENAME=bionic
Package files:
100 /var/lib/dpkg/status
release a=now
500 https://apt.kubernetes.io kubernetes-xenial/main amd64 Packages
release o=kubernetes-xenial,a=kubernetes-xenial,n=kubernetes-xenial,l=kubernetes-xenial,c=main,b=amd64
origin apt.kubernetes.io
500 http://archive.ubuntu.com/ubuntu bionic-updates/main amd64 Packages
release v=18.04,o=Ubuntu,a=bionic-updates,n=bionic,l=Ubuntu,c=main,b=amd64
origin archive.ubuntu.com
500 https://download.docker.com/linux/ubuntu bionic/edge amd64 Packages
release o=Docker,a=bionic,l=Docker CE,c=edge,b=amd64
origin download.docker.com
500 https://download.docker.com/linux/ubuntu bionic/stable amd64 Packages
release o=Docker,a=bionic,l=Docker CE,c=stable,b=amd64
origin download.docker.com
500 http://archive.ubuntu.com/ubuntu bionic-security/main amd64 Packages
release v=18.04,o=Ubuntu,a=bionic-security,n=bionic,l=Ubuntu,c=main,b=amd64
origin archive.ubuntu.com
500 http://archive.ubuntu.com/ubuntu bionic/main amd64 Packages
release v=18.04,o=Ubuntu,a=bionic,n=bionic,l=Ubuntu,c=main,b=amd64
origin archive.ubuntu.com
Pinned packages: |
@Zauxst I think I narrowed down the problem. If you run If so, edit that file so the first one ends with I think the problem is your installation of Ubuntu didn't configure the apt source lists to allow community packages to be installed and Doing that really isn't a responsibility of this role. It should be done when you bootstrap your server or configure apt IMO. |
@nickjj yes indeed, adding universe solved the problem. Thanks a lot for taking the time. I'm not going to go into a philosophical debate about it, this is my 2cent of this topic: Besides... Ubuntu=16.04 and 18.04 doesn't require gnupg2 according to the official installation. Only the Debian install does. before: cat /etc/apt/sources.list
deb http://archive.ubuntu.com/ubuntu bionic main
deb http://archive.ubuntu.com/ubuntu bionic-security main
deb http://archive.ubuntu.com/ubuntu bionic-updates main after gnupg2 was found. apt-cache search gnupg2
devscripts - scripts to make the life of a Debian Package maintainer easier
gnupg2 - GNU privacy guard - a free PGP replacement (dummy transitional package) |
Yep, but in this case, adding it for Ubuntu doesn't do any harm and while it's possible to split it up, it drastically complicates the role (both at configuration and implementation levels). My philosophy is determining whether or not to use universe, backports, etc. is a system level decision that should be configured once with an Having this role start to modify apt source lists to make a system level decision as important as that one doesn't seem reasonable IMO. But, having it as part of the documentation makes sense. It's just most cloud providers have universe enabled by default, so I didn't even think to add that. I only figured it out because I ended up setting up a stock Ubuntu server (which only allows |
Hi nick, thanks for sharing the role. It has been quite useful. I also encountered the issue on a newly provisioned aws bionic server and running the apt-update step fixed the issue. will add the it as the first step in all my future ansible playbook. |
Hi, yeah it's expected you run an apt-get update when bootstrapping a server. Otherwise you wind up in a situation explained in my previous reply. |
Ran into the same issue on a stock ubuntu 18.04 (which doesn't add universe per default).
in |
Yep, that's standard. You may want to also consider offloading that task to a designated apt / bootstrap role since it's very much system dependent. |
Installation on ubuntu 18.04 fails fails with the following error:
failed: [X.X.X.X] (item=gnupg2) => {"changed": false, "item": "gnupg2", "msg": "No package matching 'gnupg2' is available"}
ok: [X.X.X.X] => (item=cron)
On Ubuntu 18.04 package with gnupg>=2 is named just 'gnupg'
Dependencies can be overriden (thanks for it), but is inconvinient.
The text was updated successfully, but these errors were encountered: