Skip to content

Commit d7cdece

Browse files
committed
add --add-host=ip6-localhost for docker run in test
podman does not add the entry for ip6-localhost in /etc/hosts. Thus this commit adds it manually. Also, remove unused DIST_PKGS variable.
1 parent 2bfd599 commit d7cdece

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

CMakeLists.txt

+3-3
Original file line numberDiff line numberDiff line change
@@ -167,15 +167,13 @@ enable_testing()
167167
# However, ubuntu 20.04 has cmake 3.16.3. So this is a roundabout trick.
168168
list(APPEND DIST_IDS ubuntu ubuntu rocky rocky almalinux alpine)
169169
list(APPEND DIST_VERS 20.04 22.04 8.9 9.3 9.3 3.19)
170-
list(APPEND DIST_PKGS deb deb rpm rpm rpm static)
171170

172171
list(LENGTH DIST_IDS _DIST_LISTLEN)
173172
math(EXPR DIST_LISTLEN "${_DIST_LISTLEN} - 1")
174173

175174
foreach(x RANGE ${DIST_LISTLEN})
176175
list(GET DIST_IDS ${x} DIST_ID)
177176
list(GET DIST_VERS ${x} DIST_VER)
178-
list(GET DIST_PKGS ${x} DIST_PKG)
179177

180178
set(DOCKER_IMAGE mscp-${DIST_ID}:${DIST_VER})
181179
set(DOCKER_INDEX ${DIST_ID}-${DIST_VER})
@@ -203,7 +201,9 @@ foreach(x RANGE ${DIST_LISTLEN})
203201
COMMENT "Test mscp in ${DOCKER_IMAGE} container"
204202
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
205203
COMMAND
206-
${CE} run --init --rm --sysctl net.ipv6.conf.all.disable_ipv6=0
204+
${CE} run --init --rm
205+
--sysctl net.ipv6.conf.all.disable_ipv6=0
206+
--add-host=ip6-localhost:::1
207207
${DOCKER_IMAGE} /mscp/scripts/test-in-container.sh)
208208

209209
list(APPEND DOCKER_BUILDS docker-build-${DOCKER_INDEX})

0 commit comments

Comments
 (0)