Signed-off-by: Jacob Kiers <jacob@jacobkiers.net>
This commit is contained in:
		| @@ -1,4 +1,4 @@ | |||||||
| local cross_image = 'img.kie.rs/jjkiers/rust-dind-cross:1.66-slim'; | local cross_image = 'img.kie.rs/jjkiers/rust-dind-cross:1.66-sli-pm'; | ||||||
|  |  | ||||||
| local archs = [ | local archs = [ | ||||||
|   { target: 'aarch64-unknown-linux-gnu', short: 'arm64-gnu' }, |   { target: 'aarch64-unknown-linux-gnu', short: 'arm64-gnu' }, | ||||||
| @@ -16,12 +16,6 @@ local add_build_steps() = [ | |||||||
|   { |   { | ||||||
|     name: getStepName(arch), |     name: getStepName(arch), | ||||||
|     image: cross_image, |     image: cross_image, | ||||||
|     volumes: [ |  | ||||||
|       { |  | ||||||
|         name: 'dockersock', |  | ||||||
|         path: '/var/run', |  | ||||||
|       }, |  | ||||||
|     ], |  | ||||||
|     commands: [ |     commands: [ | ||||||
|       'echo Hello World from Jsonnet on ' + arch.target + '!', |       'echo Hello World from Jsonnet on ' + arch.target + '!', | ||||||
|       'cross build --release --target ' + arch.target, |       'cross build --release --target ' + arch.target, | ||||||
| @@ -46,18 +40,15 @@ local add_build_steps() = [ | |||||||
|   }, |   }, | ||||||
|   steps: |   steps: | ||||||
|     [{ |     [{ | ||||||
|       name: 'Wait for Docker', |       name: 'Start', | ||||||
|       image: cross_image, |       image: cross_image, | ||||||
|       commands: [ |       commands: [ | ||||||
|         'mkdir artifacts', |         'mkdir artifacts', | ||||||
|         'while ! docker image ls; do sleep 1; done', |         'while ! podman image ls; do sleep 1; done', | ||||||
|         'docker info', |         'podman info', | ||||||
|         'docker pull hello-world:latest', |         'podman pull hello-world:latest', | ||||||
|  |         'podman run --rm hello-world:latest', | ||||||
|       ], |       ], | ||||||
|       volumes: [{ |  | ||||||
|         name: 'dockersock', |  | ||||||
|         path: '/var/run', |  | ||||||
|       }], |  | ||||||
|     }] + |     }] + | ||||||
|     add_build_steps() + |     add_build_steps() + | ||||||
|     [ |     [ | ||||||
| @@ -87,34 +78,5 @@ 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: [ |  | ||||||
|     { |  | ||||||
|       name: 'dockersock', |  | ||||||
|       temp: {}, |  | ||||||
|     }, |  | ||||||
|     { |  | ||||||
|       name: 'docker-storage', |  | ||||||
|       host: { |  | ||||||
|         path: '/srv/drone/docker-dind-rust', |  | ||||||
|       }, |  | ||||||
|     }, |  | ||||||
|   ], |  | ||||||
|  |  | ||||||
|   image_pull_secrets: ['docker_private_repo'], |   image_pull_secrets: ['docker_private_repo'], | ||||||
| } | } | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user