lae / ansible-role-travis-lxc

Ansible role that prepares a Travis CI environment and creates LXC containers for testing roles.
MIT License
4 stars 2 forks source link

Add CentOS8 support? #43

Open martbhell opened 4 years ago

martbhell commented 4 years ago

Hello!

I don't know much about LXC - but maybe https://uk.images.linuxcontainers.org/images/centos/8/amd64/ means that there are now CentOS 8 LXC containers available?

lae commented 4 years ago

I think those images are intended to be used by LXD rather than directly by LXC, like this role currently does.

This role uses the lxc-templates package. The centos template might work, so I'll try adding a definition for CentOS 8, but it's possible it might still need to be updated in Ubuntu's PPA for LXC.

lae commented 4 years ago

I don't know if package management changed in CentOS 8 but it looks like the mirrorlist URL doesn't work for 8: http://mirrorlist.centos.org/?release=8&arch=x86_64&repo=os

LXC template depends on this at the moment. I checked a mirror manually and it looks like os and some others don't exist anymore, at least at the top-level (it looks like they've been reorganized?): http://sjc.edge.kernel.org/centos/8.0.1905/ (vs. http://sjc.edge.kernel.org/centos/7/). Someone appears to have raised an issue about this too at https://github.com/lxc/lxc-templates/issues/21.

Checking out the referenced issue, it looks like I can try to use the download template with LXC directly against the images you linked, but that'll require a bit more work. Doing this should probably help with updating the role to use Xenial/Bionic (as opposed to switching to LXD), too, so I'll see if I can get around to it soon.

martbhell commented 4 years ago

Thank you for looking into this! CentOS 8 is still early. There are now kvm, qcow2 images available either and they suggest opening bug reports in their bug tracker.

About LXD I've seen some travis blog posts recently about LXD and maybe there's some now more travis native way to test more operating systems with that. For example OpenSSL I think has some nice examples.

Edit: turns out they only have Ubuntu support with LXD right now