Project

Profile

Help

Issue #2720

closed

Can't sync file repo that uses basic auth

Added by daviddavis about 5 years ago. Updated about 3 years ago.

Status:
CLOSED - CURRENTRELEASE
Priority:
High
Assignee:
Sprint/Milestone:
-
Start date:
Due date:
Estimated time:
Severity:
3. High
Version:
Platform Release:
2.13.1
OS:
Triaged:
Yes
Groomed:
No
Sprint Candidate:
No
Tags:
Pulp 2
Sprint:
Sprint 18
Quarter:

Description

I have a repo which has a username and password set on its importer:

  Config:               
    Basic Auth Password: *****
    Basic Auth Username: labuser
    Feed:                http://repo.example.com/repos/locked

However, I get a 401 when it attempts to sync this repo:

pulp_rpm.plugins.importers.iso.sync:ERROR: Failed to download http://repo.example.com/repos/locked/PULP_MANIFEST: Unauthorized.

I can confirm that the username/pass works though by curling or browsing to the url.

Actions #1

Updated by daviddavis about 5 years ago

@beav indicated that it looks like the user/pass aren't being used when the http request is being made.

Actions #2

Updated by daviddavis about 5 years ago

  • Subject changed from Can't download file repo that uses basic auth to Can't sync file repo that uses basic auth
Actions #3

Updated by ttereshc about 5 years ago

  • Priority changed from Normal to High
  • Sprint/Milestone set to 37
  • Severity changed from 2. Medium to 3. High
  • Triaged changed from No to Yes
Actions #4

Updated by daviddavis about 5 years ago

  • Status changed from NEW to ASSIGNED
  • Assignee set to daviddavis

Added by daviddavis about 5 years ago

Revision b86b71f1

Fix file syncs that require basic auth

fixes #2720 https://pulp.plan.io/issues/2720

Actions #5

Updated by daviddavis about 5 years ago

  • Status changed from ASSIGNED to POST
Actions #6

Updated by daviddavis about 5 years ago

  • Status changed from POST to MODIFIED
Actions #8

Updated by bizhang about 5 years ago

  • Platform Release set to 2.13.1
Actions #9

Updated by bizhang about 5 years ago

  • Status changed from MODIFIED to 5
Actions #10

Updated by pthomas@redhat.com about 5 years ago


[root@qe-blade-12 ~]# pulp-admin iso repo create --repo-id  protected-file --feed http://file.rdu.redhat.com/~pthomas/file-protected/ --relative-url iso-repo
Successfully created repository [protected-file]

[root@qe-blade-12 ~]# 
[root@qe-blade-12 ~]# 
[root@qe-blade-12 ~]# 
[root@qe-blade-12 ~]# pulp-admin rpm repo sync run --repo-id protected-file
+----------------------------------------------------------------------+
               Synchronizing Repository [protected-file]
+----------------------------------------------------------------------+

This command may be exited via ctrl+c without affecting the request.

Task Failed

Importer indicated a failed response

[root@qe-blade-12 ~]# pulp-admin rpm repo update --repo-id  protected-file --basicauth-user testuser --basicauth-pass redhat --feed http://file.rdu.redhat.com/~pthomas/file-protected/  
Repository [protected-file] successfully updated

[root@qe-blade-12 ~]# 
[root@qe-blade-12 ~]# 
[root@qe-blade-12 ~]# 
[root@qe-blade-12 ~]# pulp-admin rpm repo sync run --repo-id protected-file
+----------------------------------------------------------------------+
               Synchronizing Repository [protected-file]
+----------------------------------------------------------------------+

This command may be exited via ctrl+c without affecting the request.

Task Succeeded

Task Succeeded

[root@qe-blade-12 ~]# pulp-admin iso repo list
+----------------------------------------------------------------------+
                            ISO Repositories
+----------------------------------------------------------------------+

Id:                  protected-file
Display Name:        None
Description:         None
Content Unit Counts: 
  Iso: 3
Actions #12

Updated by bizhang about 5 years ago

  • Status changed from 5 to CLOSED - CURRENTRELEASE
Actions #13

Updated by bmbouter about 4 years ago

  • Sprint set to Sprint 18
Actions #14

Updated by bmbouter about 4 years ago

  • Sprint/Milestone deleted (37)
Actions #15

Updated by bmbouter about 3 years ago

  • Tags Pulp 2 added

Also available in: Atom PDF