Custom Docker Repository URL for Artifactory and Jenkins

I’m trying to get the Docker Build and Publish plugin working on our Jenkins instance. The Docker image is getting built correctly, but I’m having issues with getting this image pushed to our Artifactory Docker Repository.

The Artifactory repository is hosted at

  • Docker-compose and custom packages
  • Mounting linux container on windows host
  • Docker Sidekiq Starting - Rails App with Puma
  • Curl command to install docker-machine and/or docker-compose does not work in Ubuntu Xenial
  • Issues with Running Flask and SQLAlchemy app through Docker
  • docker pull/push not working with insecure registry
  • When I look in the logs for the build, it fails to upload the Docker image, but the url looks like Here is the output from the log:

    [workspace] $ docker push
    The push refers to a repository [] (len: 1)
    Sending image list
    Error: Status 405 trying to push repository test-docker-build: "<!DOCTYPE HTML PUBLIC \"-//IETF//DTD HTML 2.0//EN\">\n<html><head>\n<title>405 Method Not Allowed</title>\n</head><body>\n<h1>Method Not Allowed</h1>\n<p>The requested method PUT is not allowed for the URL /v1/repositories/test-docker-build/.</p>\n</body></html>\n"
    Build step 'Docker Build and Publish' marked build as failure
    Finished: FAILURE

    I am assuming that it is failing because the repository URL is incorrect. I have also tried logging into the backend and pushing via the command line with the correct repository URL and that doesn’t seem to work either.

    My main question is: does docker not like the URL structure since it uses the ‘/’ to denote user/image name? I.E. would this work if the url didn’t include the /artifactory?

    Any ideas would be greatly appreciated!

  • Docker compose - build order, database before the app
  • Why do I get an authorization error from Docker when I'm trying to pull a public image?
  • MongoDB Script with rs.add() Not Executing As Expected
  • localhost:8000 resolves to localhost and “this site can't be reached” but localhost:8000/services works
  • Docker Compose: Change env variables
  • What is wrong in my docker-compose.yml file?
  • One Solution collect form web for “Custom Docker Repository URL for Artifactory and Jenkins”

    The response you’re getting back looks like something a reverse proxy would return (nginx\apache), not Artifactory – did you follow the instructions on how to set up a Reverse Proxy with Artifactory?

    Usually you would need to:

    • set up the reverse proxy for docker usage correctly
    • either get a certificate for and use it in the proxy or set up Artifactory as an insecure registry (beware of this – should not be used in production)

    Once you did these you will reference the Artifactory instance as no need for /artifactory or anything else.
    The url you posted is what the reverse proxy should use when directing to Artifactory (i.e.

    Then usage would look like docker push

    Docker will be the best open platform for developers and sysadmins to build, ship, and run distributed applications.