Fix tripleo-repos molecule to run on CentOS/RHEL 8

The current molecule configuration for the tripleo-repos role only
works fine on CentOS 7, since it requires several python2 packages.

Removing the dockerfile switches to the embedded support from molecule.

Depends-On: https://review.rdoproject.org/r/27300
Change-Id: Ic2b5e1d9dcf7bef72cca4be64a46c49d5ccc8bfd
This commit is contained in:
Javier Pena 2020-05-08 11:29:39 +02:00 committed by zbr
parent 3c03fb3f65
commit 9a73e91cdc
2 changed files with 0 additions and 22 deletions

View File

@ -1,21 +0,0 @@
# Molecule managed
{% if item.registry is defined %}
FROM {{ item.registry.url }}/{{ item.image }}
{% else %}
FROM {{ item.image }}
{% endif %}
RUN if [ $(command -v apt-get) ]; then apt-get update && apt-get install -y python sudo bash ca-certificates && apt-get clean; \
elif [ $(command -v dnf) ]; then dnf makecache && dnf --assumeyes install python sudo python-devel python*-dnf bash {{ item.pkg_extras | default('') }} && dnf clean all; \
elif [ $(command -v yum) ]; then yum makecache fast && yum install -y python sudo yum-plugin-ovl python-setuptools bash {{ item.pkg_extras | default('') }} && sed -i 's/plugins=0/plugins=1/g' /etc/yum.conf && yum clean all; \
elif [ $(command -v zypper) ]; then zypper refresh && zypper install -y python sudo bash python-xml {{ item.pkg_extras | default('') }} && zypper clean -a; \
elif [ $(command -v apk) ]; then apk update && apk add --no-cache python sudo bash ca-certificates {{ item.pkg_extras | default('') }}; \
elif [ $(command -v xbps-install) ]; then xbps-install -Syu && xbps-install -y python sudo bash ca-certificates {{ item.pkg_extras | default('') }} && xbps-remove -O; fi
{% for pkg in item.easy_install | default([]) %}
# install pip for centos where there is no python-pip rpm in default repos
RUN easy_install {{ pkg }}
{% endfor %}
CMD ["sh", "-c", "while true; do sleep 10000; done"]

View File

@ -10,7 +10,6 @@ platforms:
hostname: ${MOLECULE_PLATFORM:-centos7}
image: ${MOLECULE_IMAGE:-centos:7}
dockerfile: ../Dockerfile.j2
pkg_extras: python-setuptools
easy_install: [pip]
environment: &env
http_proxy: "{{ lookup('env', 'http_proxy') }}"