Re: [libvirt-jenkins-ci PATCH] lcitool: Fix $PYTHON value in environment

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Apr 03, 2020 at 01:19:41PM +0200, Andrea Bolognani wrote:
> Starting with commit
> 
>   commit d76f41ece09b9aaf492553fe466c30a22c78e509
>   Author: Andrea Bolognani <abologna@xxxxxxxxxx>
>   Date:   Fri Mar 27 17:21:26 2020 +0100
> 
>     lcitool: Include paths in the inventory
> 
>     Figuring them out at runtime is neat, but in practice they don't
>     change frequently enough for it to be necessary; more importantly,
>     including them in the inventory means we can use them in the
>     Dockerfile generator in addition to the Ansible playbooks.
> 
>     Signed-off-by: Andrea Bolognani <abologna@xxxxxxxxxx>
>     Reviewed-by: Daniel P. Berrangé <berrange@xxxxxxxxxx>
> 
> we have hardcoded the path of the Python interpreter to be used for
> builds in the inventory; an unforeseen consequence of this change is
> that Python builds on CentOS 7 have started failing. The reason for
> that is simple, but not immediately obvious.
> 
> While on most target platforms we have a single Python interpreter
> installed, on CentOS 7 we still need two: Python 3 works fine when
> it comes to building projects, but it's missing a bunch of modules
> that Ansible needs to run, so we're stuck with Python 2 for Ansible
> use. This has worked fine for us so far.
> 
> As part of the change above, however, due to a naming clash we have
> ended up in a situation where the bootstrap task, which installs a
> Python suitable for Ansible, overrides the Python intended for builds
> as set in the inventory. Of course this would result in breakages
> only on CentOS 7, where the two Pythons differ.
> 
> Fix this by removing the runtime detection from the bootstrap task
> and storing the relevant information in the inventory.
> 
> Signed-off-by: Andrea Bolognani <abologna@xxxxxxxxxx>
> ---
>  guests/host_vars/libvirt-centos-7/main.yml        |  1 +
>  guests/host_vars/libvirt-centos-8/main.yml        |  1 +
>  guests/host_vars/libvirt-debian-10/main.yml       |  1 +
>  guests/host_vars/libvirt-debian-9/main.yml        |  1 +
>  guests/host_vars/libvirt-debian-sid/main.yml      |  1 +
>  guests/host_vars/libvirt-fedora-30/main.yml       |  1 +
>  guests/host_vars/libvirt-fedora-31/main.yml       |  1 +
>  guests/host_vars/libvirt-fedora-rawhide/main.yml  |  1 +
>  guests/host_vars/libvirt-freebsd-11/main.yml      |  1 +
>  guests/host_vars/libvirt-freebsd-12/main.yml      |  1 +
>  guests/host_vars/libvirt-freebsd-current/main.yml |  1 +
>  guests/host_vars/libvirt-opensuse-151/main.yml    |  1 +
>  guests/host_vars/libvirt-ubuntu-1604/main.yml     |  1 +
>  guests/host_vars/libvirt-ubuntu-1804/main.yml     |  1 +
>  guests/playbooks/update/tasks/bootstrap.yml       | 11 +----------
>  15 files changed, 15 insertions(+), 10 deletions(-)

Reviewed-by: Daniel P. Berrangé <berrange@xxxxxxxxxx>


Regards,
Daniel
-- 
|: https://berrange.com      -o-    https://www.flickr.com/photos/dberrange :|
|: https://libvirt.org         -o-            https://fstop138.berrange.com :|
|: https://entangle-photo.org    -o-    https://www.instagram.com/dberrange :|





[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux