Allow to provide arguments to the docker.build command

This issue is archived. You can view it, but you can't modify it. Learn more

XMLWordPrintable

      At the moment, it is not possible to apply arguments for the `docker.build` command.

      For example, if I want to use the `--pull` flag to ensures that the base image is the latest version, I need to use either:

      sh "docker build --pull -t name ."
      dockerFingerprintFrom dockerfile: 'Dockerfile', image: 'name', toolName: env.DOCKER_TOOL_NAME
      def img = docker.image('name')
      

      or

      docker.image('the-base-image').pull()
      docker.build(…as before…)
      

            Assignee:
            Pete Wagner
            Reporter:
            Allan BURDAJEWICZ
            Archiver:
            Jenkins Service Account

              Created:
              Updated:
              Resolved:
              Archived: