1

I'm using Docker plugin for Jenkins.

when I configure new docker cloud with docker template everything works as expected(Jenkins spins off a container and do the job) but now I have a new build job that requires more disk space and my job failing on: "not enough disk space" in the container.

I want to add --storage-opt size=15G to the docker template in Jenkins to allow the docker to be bigger than the default 10G it has. unfortunately, whatever I tried it did not respond and in some cases, it failed with the error :

Reason: Template provisioning failed.
com.github.dockerjava.api.exception.BadRequestException: {"message":"OCI runtime create failed: container_linux.go:345: starting container process caused \"exec: \\\"--storage-opt\\\": executable file not found in $PATH\": unknown"} 

what am I missing, how should I pass the arguments? thanks!

alex
  • 916
  • 4
  • 12
  • 26
  • How you are passing the `--storage-opt-size`? can you try with `docker { image 'maven:3-alpine' args ' --storage-opt size=15G' }` – Adiii Mar 08 '20 at 06:56
  • I'm using docker Cloud configuration in Jenkins configure, not dockerfile. I'm moving my jobs from physical servers to dockers. I tried adding the parameter to Docker Command inside the docker template . @Adiii – alex Mar 08 '20 at 07:14
  • What does your docker template look like? – gigalul Mar 08 '20 at 07:48

0 Answers0