Go back to docker-in-docker
continuous-integration/drone/push Build is passing Details

Signed-off-by: Jacob Kiers <jacob@jacobkiers.net>
This commit is contained in:
Jacob Kiers 2022-12-27 21:07:41 +01:00
parent f61e635721
commit 71371cb3e1
1 changed files with 21 additions and 7 deletions

View File

@ -19,7 +19,7 @@ local add_build_steps() = [
volumes: [ volumes: [
{ {
name: 'dockersock', name: 'dockersock',
path: '/var/run/docker.sock', path: '/var/run',
}, },
], ],
commands: [ commands: [
@ -29,7 +29,7 @@ local add_build_steps() = [
'rm -rf target/' + arch.target + '/release/*', 'rm -rf target/' + arch.target + '/release/*',
], ],
environment: { environment: {
CROSS_DOCKER_IN_DOCKER: true, CROSS_REMOTE: true,
}, },
depends_on: ['Wait for Docker'], depends_on: ['Wait for Docker'],
} }
@ -57,11 +57,11 @@ local add_build_steps() = [
'docker pull hello-world:latest', 'docker pull hello-world:latest',
], ],
environment: { environment: {
CROSS_DOCKER_IN_DOCKER: true, CROSS_REMOTE: true,
}, },
volumes: [{ volumes: [{
name: 'dockersock', name: 'dockersock',
path: '/var/run/docker.sock', path: '/var/run',
}], }],
}] + }] +
add_build_steps() + add_build_steps() +
@ -92,12 +92,26 @@ local add_build_steps() = [
}, },
], ],
services: [{
name: 'docker',
image: 'docker:dind',
privileged: true,
volumes: [
{
name: 'dockersock',
path: '/var/run',
},
{
name: 'docker-storage',
path: '/var/lib/docker',
},
],
}],
volumes: [ volumes: [
{ {
name: 'dockersock', name: 'dockersock',
host: { temp: {},
path: '/var/run/docker.sock',
},
}, },
], ],