Commit Graph

8 Commits (3c0e06ea0cdf3098497274dd8ff5a63b117d20c5)

Author SHA1 Message Date
Johannes Kastl a1811ca097 install python-xml on SUSE/openSUSE only if python2 is installed
raw_install_python.yml: on SUSE/openSUSE, install python-xml package only
if python2 is installed already

Background:
On SLES 15.x / openSUSE Leap 15.x, the python2 package `python-base` provides
/usr/bin/python, while python3 only provides /usr/bin/python3.

Signed-off-by: Johannes Kastl <kastl@b1-systems.de>
2019-09-27 14:19:32 +02:00
Dimitri Savineau f90696c36e rhel8: add default python bin path
On RHEL 8 system we should check the /usr/libexec/platform-python path
instead of installing python36 package.

[DEPRECATION WARNING]: Distribution redhat 8.0 on host xxxxx should use
/usr/libexec/platform-python, but is using /usr/bin/python for backward
compatibility with prior Ansible releases. A future Ansible release will
default to using the discovered platform python for this host.

Signed-off-by: Dimitri Savineau <dsavinea@redhat.com>
2019-09-18 14:35:53 +02:00
Johannes Kastl 8e3511ddc7 fix SUSE/openSUSE naming
As SUSE 15.x and openSUSE Leap 15.x share the same base, make clear
that both are targeted by the respective tasks

Signed-off-by: Johannes Kastl <kastl@b1-systems.de>
2019-08-22 17:20:21 +02:00
Guillaume Abrioux d3fa3c2d72 refact python installation
This commit refacts the python installation when no available.

In order to avoid generating errors, we check for each package manager
to detect which system we are running on.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
2019-08-14 16:42:02 +02:00
Rishabh Dave 739a662c80 improve coding style
Keywords requiring only one item shouldn't express it by creating a
list with single item.

Signed-off-by: Rishabh Dave <ridave@redhat.com>
2019-04-23 15:37:07 +02:00
Guillaume Abrioux c43b30e3ce common: fix retry on raw install python for rhel
when the following failure is thrown
```
    rhel-8.0.0-beta-1.7-     [===                 ] ---  B/s |   0  B     --:-- ETArhel-8.0.0-beta-1.7-appstream                   0.0  B/s |   0  B     00:00
    rhel-8.0.0-beta-1.7-     [===                 ] ---  B/s |   0  B     --:-- ETArhel-8.0.0-beta-1.7-baseos                      0.0  B/s |   0  B     00:00
    rhel-8.0.0-beta-1.7-     [   ===              ] ---  B/s |   0  B     --:-- ETArhel-8.0.0-beta-1.7-builder                     0.0  B/s |   0  B     00:00
    Failed to synchronize cache for repo 'rhel-8.0.0-beta-1.7-appstream', ignoring this repo.
    Failed to synchronize cache for repo 'rhel-8.0.0-beta-1.7-baseos', ignoring this repo.
    Failed to synchronize cache for repo 'rhel-8.0.0-beta-1.7-builder', ignoring this repo.
    No match for argument: python3
    Error: Unable to find a match
```

dnf returns 0 anyway.

Let's ensure the pattern 'Failed' isn't present in the output.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
2019-02-25 10:05:34 +00:00
Guillaume Abrioux 7f7f3769b3 main: add a retry/until for python installation
Add a retry/until in raw_install_python.yml to avoid unexpected
repository failures.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
2019-02-19 16:40:08 +01:00
Guillaume Abrioux b94290af43 refact the 'raw' installation of python
to avoid duplicating code in `site.yml.sample`, `site-docker.yml.sample`
and `setup.yml`, let's isolate this part of the code and simply include
it each time we need it.

Signed-off-by: Guillaume Abrioux <gabrioux@redhat.com>
2019-01-16 10:16:11 +01:00