diff --git a/molecule/centos-9-build/Dockerfile b/molecule/centos-9-build/Dockerfile new file mode 100644 index 0000000000000000000000000000000000000000..8d94345448ea526148e026350419b563d77608e3 --- /dev/null +++ b/molecule/centos-9-build/Dockerfile @@ -0,0 +1,30 @@ +FROM quay.io/centos/centos:stream9 +ENV container=docker + +RUN rm -fv /var/cache/dnf/metadata_lock.pid; \ +dnf makecache; \ +dnf --assumeyes install \ + /usr/bin/python3 \ + /usr/bin/python3-config \ + /usr/bin/dnf-3 \ + sudo \ + bash \ + systemd \ + procps-ng \ + iproute && \ +dnf clean all; \ +(cd /lib/systemd/system/sysinit.target.wants/; for i in *; do [ $i == systemd-tmpfiles-setup.service ] || rm -f $i; done); \ +rm -f /lib/systemd/system/multi-user.target.wants/*;\ +rm -f /etc/systemd/system/*.wants/*;\ +rm -f /lib/systemd/system/local-fs.target.wants/*; \ +rm -f /lib/systemd/system/sockets.target.wants/*udev*; \ +rm -f /lib/systemd/system/sockets.target.wants/*initctl*; \ +rm -f /lib/systemd/system/basic.target.wants/*;\ +rm -f /lib/systemd/system/anaconda.target.wants/*; \ +rm -rf /var/cache/dnf/; + +STOPSIGNAL RTMIN+3 + +VOLUME ["/sys/fs/cgroup"] + +CMD ["/usr/sbin/init"] diff --git a/molecule/centos-9-build/molecule.yml b/molecule/centos-9-build/molecule.yml new file mode 100644 index 0000000000000000000000000000000000000000..c3f64c92924fac7e743a59d62daafce8a499fd04 --- /dev/null +++ b/molecule/centos-9-build/molecule.yml @@ -0,0 +1,18 @@ +--- +driver: + name: docker +platforms: + - name: centos-9-build + image: "quay.io/centos/centos:stream9" + dockerfile: Dockerfile + hostname: ipaserver.test.local + dns_servers: + - 8.8.8.8 + volumes: + - /sys/fs/cgroup:/sys/fs/cgroup:ro + command: /usr/sbin/init + privileged: true +provisioner: + name: ansible + playbooks: + prepare: ../resources/playbooks/prepare-build.yml diff --git a/tests/azure/build-containers.yml b/tests/azure/build-containers.yml index 20d6d7e8f4c9268d0a1170c61c97422b0f0bef70..633eb825452e38ca8f3ded242b8c65ce84d728a1 100644 --- a/tests/azure/build-containers.yml +++ b/tests/azure/build-containers.yml @@ -27,6 +27,12 @@ jobs: container_name: centos-8 build_scenario_name: centos-8-build +- template: templates/build_container.yml + parameters: + job_name_suffix: Centos9 + container_name: centos-9 + build_scenario_name: centos-9-build + - template: templates/build_container.yml parameters: job_name_suffix: FedoraLatest