Skip to content

Commit 991a2db

Browse files
authored
Merge pull request gocd#11408 from chadlwilson/correct-dind-image-verification
Allow dind image to be correctly verified
2 parents 67c030c + fcae070 commit 991a2db

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

docker/gocd-agent/build.gradle

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -116,8 +116,9 @@ subprojects {
116116
// daemonize the container
117117
cleanContainer.call() // Clean-up after any previous aborted runs
118118
project.exec {
119+
def additionalFlags = distro == Distro.docker ? ["--privileged"] : []
119120
workingDir = project.rootProject.projectDir
120-
commandLine = ["docker", "run", "-e", "GO_SERVER_URL=http://localhost:8153/go", "-d", "--name", docker.dockerImageName, docker.imageNameWithTag]
121+
commandLine = ["docker", "run", "-e", "GO_SERVER_URL=http://localhost:8153/go", "-d", "--name", docker.dockerImageName] + additionalFlags + [docker.imageNameWithTag] as List<String>
121122
standardOutput = System.out
122123
errorOutput = System.err
123124
}

0 commit comments

Comments
 (0)