Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-33150

volume that uses environment variable as the source is mounted twice


      Each slave defines an environment variable named REPOSITORIES that points to a local directory. Build jobs should mount that directory inside containers for use a Maven cache.

      1. Configure a build job with a docker Build Environment
      2. Specify a volume for the image where "Path on host" is "$REPOSITORIES" and "Path inside container" is "/repositories"
      3. Run the build

      When the build runs the following command is invoked duplicating the volume parameter:

      docker run --tty --detach --workdir /jenkins/workspace/build --volume /cache/repositories:/repositories:rw --volume $REPOSITORIES:/repositories:rw --volume /tmp:/tmp:rw --net bridge ...

      On the docker host an unexpected directory named "/cache/repositories:" is created.

      The mount point inside the container works as expected but the additional directory and volume parameter are not expected.

            Unassigned Unassigned
            spingel Steffen Pingel
            1 Vote for this issue
            2 Start watching this issue