Uploaded image for project: 'Artifactory Binary Repository'
  1. Artifactory Binary Repository
  2. RTFACT-13807

Artifactory doesn't pass headers when using /api/vagrant

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open
    • Priority: High
    • Resolution: Unresolved
    • Affects Version/s: 4.6.0, 4.15.0, 4.16.0, 5.1.0
    • Fix Version/s: None
    • Component/s: Vagrant
    • Labels:
      None

      Description

      Sub title: Artifactory doesn't support Vagrant retry mechanism.
      Info: Under the hood Vagrant uses curl with "--continue-at" as its retry mechanism. However, when addressing /api/vagrant/ Artifactory does not pass the headers and therefore doesn't pass on the HTTP Range header.

      Steps to reproduce:
      1. Have an Artifactory with a vagrant repo with at least one box
      2. Use "vagrant box add" with the '--debug' option
      3. You should see that the vagrant client uses curl with a request similar to:
      Starting process: ["/usr/bin/curl", "q", "fail", "location", "max-redirs", "10", "user-agent", "Vagrant/1.8.1 (+https://www.vagrantup.com; ruby2.3.1)", "continue-at", "", "--output", "/home/

      {user}

      /.vagrant.d/tmp/box7b7971c9c113f792fdaf1f42ab15a12f9963290a", "http://

      {server}

      :

      {port}

      /artifactory/api/vagrant/vagrant-local/trusty-server-cloudimg-amd64-vagrant-disk1.box"]

      4. Use the above curl request to download the box
      5. cut the connection halfway through
      6. Try to continue (by using the same curl request)
      7. you will fail with :
      curl: (33) HTTP server doesn't seem to support byte ranges. Cannot resume.

      8. retry '6' but this time remove the '/api/vagrant/
      9. The request succeeds.

      **running curl with -vv will show that when using /api/vagrant/ the "Content-Range" header is not returned.

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            eranb Eran Blumenthal
            Votes:
            4 Vote for this issue
            Watchers:
            4 Start watching this issue

              Dates

              Created:
              Updated: