Bug 649765

Summary: [RFE] upload without specifying a repo
Product: [Retired] Pulp Reporter: Daniel Mach <dmach>
Component: z_otherAssignee: Pradeep Kilambi <pkilambi>
Status: CLOSED CURRENTRELEASE QA Contact: Preethi Thomas <pthomas>
Severity: medium Docs Contact:
Priority: medium    
Version: unspecifiedCC: skarmark, tsanders
Target Milestone: ---Keywords: FutureFeature, Triaged
Target Release: Sprint 21   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2011-08-15 15:14:30 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 563609, 647488, 673012    

Description Daniel Mach 2010-11-04 14:12:25 UTC
rhnpush can perform a 'nochannel' push to upload files in preparation to a release. Another push only subscribes these files to channels (repos), which is significantly faster, because no files are transfered this time.

Can you modify pulp to support this scenario?
Following 2 actions are needed to do so:
- upload a file without specifying a repo
- attach the file (identified probably by (name, checksum)) to a repo
  - allow to specify more repos and files at once

The benefit is also in uploading lots and lots of files - files are uploaded first, subscribed to repos later -> it makes uploads more atomic from consumer's perspective

Comment 1 Daniel Mach 2011-02-09 21:50:04 UTC
$ sha256sum signed/bash-4.1.2-8.el6.i686.rpm 
f1e6d6b2896fab6accaafebc9a9c7f6d3367516dbdea4d5af142e2a7cff71771  signed/bash-4.1.2-8.el6.i686.rpm

$ sha256sum unsigned/bash-4.1.2-8.el6.i686.rpm 
3de776d3a999ab65998a89e561c5bcffad3b5ac16963fc10fcd2f12b1d922606  unsigned/bash-4.1.2-8.el6.i686.rpm


Uploading *unsigned* copy of a RPM:
$ pulp-admin package upload unsigned/bash-4.1.2-8.el6.i686.rpm 
STEP: ** Performing Package Uploads to Pulp server **
Successfully uploaded [bash-4.1.2-8.el6.i686.rpm] to server

Uploading *signed* copy of a RPM:
$ pulp-admin --username=admin --password=admin package upload signed/bash-4.1.2-8.el6.i686.rpm 
STEP: ** Performing Package Uploads to Pulp server **
Package [bash-4.1.2-8.el6.i686.rpm] already exists on the server with checksum [{'sha256': '3de776d3a999ab65998a89e561c5bcffad3b5ac16963fc10fcd2f12b1d922606'}]


-> Can't upload a different RPM with the same N-V-R.A to server.
We'll need to distinguish uploaded file by file_name (or NVRA) and sha256sum.

Comment 2 Todd Sanders 2011-03-10 21:03:05 UTC
Addressed in Sprint 21.  -tsanders

Comment 3 Preethi Thomas 2011-05-06 17:50:25 UTC
verified
[root@preethi ~]# rpm -q pulp
pulp-0.0.173-1.fc14.noarch


[root@preethi ~]# pulp-admin content upload upload/pulp-0.0.168-1.fc14.noarch.rpm --nosig -v
* Starting Content Upload

* Performing Content Uploads to Pulp server
Successfully uploaded [pulp-0.0.168-1.fc14.noarch.rpm] to server

* Content Upload complete.

Comment 4 Preethi Thomas 2011-08-15 15:14:30 UTC
Closing with current community release

pulp-0.0.223