Bug 949004 - The ISO Importer does not build the URL for the PULP_MANIFEST correctly
Summary: The ISO Importer does not build the URL for the PULP_MANIFEST correctly
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Pulp
Classification: Retired
Component: rpm-support
Version: 2.1 Beta
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
: 2.1.1
Assignee: Randy Barlow
QA Contact: Preethi Thomas
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-04-05 15:53 UTC by Randy Barlow
Modified: 2013-09-10 15:44 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-09-10 15:44:10 UTC
Embargoed:


Attachments (Terms of Use)

Description Randy Barlow 2013-04-05 15:53:18 UTC
In the ISO Importer refactor, I neglected to remember that urljoin only does what I want in building the URL for the PULP_MANIFEST if the repo_url ends in a trailing slash.

The fix is to add this bit to the importer's __init__() method when setting self._repo_url:

+        # The _repo_url must end in a trailing slash, because we will use urljoin to determine the path to
+        # PULP_MANIFEST later
+        if self._repo_url[-1] != '/':
+            self._repo_url = self._repo_url + '/'

Obviously, we need a good unit test for this too to make sure it doesn't happen again. We will need this fix for 2.1.1 and also for master.

Comment 2 Randy Barlow 2013-04-06 17:10:39 UTC
This is fixed by https://github.com/pulp/pulp_rpm/pull/172

Comment 3 Randy Barlow 2013-04-08 20:09:05 UTC
Merged.

Comment 4 Randy Barlow 2013-06-20 17:56:00 UTC
I mistakenly set this to MODIFIED when it should be set to POST.

Comment 5 Randy Barlow 2013-06-20 17:58:10 UTC
This was merged into the 2.1 branch before 2.1.1 was released.

Comment 6 Michael Hrivnak 2013-08-02 14:48:46 UTC
build 2.1.1-0.1.beta

Comment 7 Preethi Thomas 2013-08-08 01:39:55 UTC
verified

[root@cloud-qe-14 ~]#  pulp-admin iso repo create --repo-id iso --feed https://cdn.redhat.com/content/dist/rhel/server/6/6Server/x86_64/iso   --feed-ca-cert CDN/cdn.redhat.com-chain.crt --feed-cert CDN/1359391926_4512.crt  --feed-key CDN/1359391926_4512.key
Successfully created repository [iso]

[root@cloud-qe-14 ~]# 
[root@cloud-qe-14 ~]# 
[root@cloud-qe-14 ~]# 
[root@cloud-qe-14 ~]# pulp-admin iso repo sync run --repo-id iso
+----------------------------------------------------------------------+
                     Synchronizing Repository [iso]
+----------------------------------------------------------------------+

This command may be exited by pressing ctrl+c without affecting the actual
operation on the server.

Downloading the Pulp Manifest...
The Pulp Manifest was downloaded successfully.

Downloading 5 ISOs...
[==================================================] 100%
ISOs: 5/5	Data: 10.2 GB/10.2 GB	Avg: 1.5 MB/s


Successfully downloaded 5 ISOs.

The repository was successfully published.

[root@cloud-qe-14 ~]# 


[root@cloud-qe-1-vm-1 ~]# pulp-admin iso repo create --repo-id iso --feed https://cdn.redhat.com/content/dist/rhel/server/6/6Server/x86_64/iso/ --feed-ca-cert CDN/cdn.redhat.com-chain.crt --feed-cert CDN/1359391926_4512.crt  --feed-key CDN/1359391926_4512.key
Successfully created repository [iso]

[root@cloud-qe-1-vm-1 ~]#  pulp-admin iso repo sync run --repo-id iso+----------------------------------------------------------------------+
                     Synchronizing Repository [iso]
+----------------------------------------------------------------------+

This command may be exited by pressing ctrl+c without affecting the actual
operation on the server.

Downloading the Pulp Manifest...
The Pulp Manifest was downloaded successfully.

Downloading 5 ISOs...
[========                                          ] 17%
ISOs: 2/5	Data: 1.8 GB/10.2 GB	Avg: 758.7 kB/s
^C[root@cloud-qe-1-vm-1 ~]#

Comment 8 Preethi Thomas 2013-09-10 15:44:10 UTC
2.2 released
http://repos.fedorapeople.org/repos/pulp/pulp/stable/2.2/


Note You need to log in before you can comment on or make changes to this bug.