Skip to content
This repository was archived by the owner on Sep 14, 2023. It is now read-only.

Commit c6834ee

Browse files
committed
testing: assure we run containers with network mode host
Avoids failure to install packages on docker hosts that are not configured to enable internet access by default.
1 parent 70de5ab commit c6834ee

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

tests/roles/ensure-ansible/molecule/default/molecule.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,34 +2,40 @@
22
driver:
33
name: docker
44

5+
# network_mode: host needed to assure internet access
56
platforms:
67

78
- name: centos7
89
hostname: centos7
910
image: centos:7
1011
dockerfile: ../Dockerfile.j2
12+
network_mode: host
1113

1214
- name: fedora
1315
hostname: fedora
1416
image: fedora:latest
1517
dockerfile: ../Dockerfile.j2
18+
network_mode: host
1619

1720
- name: rhel8
1821
hostname: rhel8
1922
image: ubi8/python-36
2023
registry:
2124
url: registry.access.redhat.com
2225
dockerfile: ../Dockerfile.j2
26+
network_mode: host
2327

2428
- name: ubuntu
2529
hostname: ubuntu
2630
image: ubuntu:latest
2731
dockerfile: ../Dockerfile.j2
32+
network_mode: host
2833

2934
- name: debian
3035
hostname: debian
3136
image: debian:latest
3237
dockerfile: ../Dockerfile.j2
38+
network_mode: host
3339

3440
provisioner:
3541
name: ansible

0 commit comments

Comments
 (0)