apt-key with HKP keyserver

I’m trying to follow the instructions for installing MaraDB apt package (https://downloads.mariadb.org/mariadb/repositories/#distro=Ubuntu&distro_release=precise&version=5.5). It proposes to add a key like this:

sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xcbcb082a1bb943db

So I tried this in the playbook:

apt_key: keyserver="hkp://keyserver.ubuntu.com:80" id=0xcbcb082a1bb943db state=present

And got the error "urlopen error unknown url type: hkp". Have I used the right syntax?

Yes, you did it right…

But I’d try changing hkp (http keyserver protocol) to http…

I’ve had similar issues with hkp before.

Adam

http doesn’t work stderr: gpg: no valid OpenPGP data found."

Maybe I should report it as a bug?

Did you ever resolve this Michael? Just hit the same OpenPGP error with MariaDB…

I’m getting the same errors with an hkp server when trying to install rmv’s gpg key.