Bug 799036 - Promoting template with repo that is not already in target environment fails
Summary: Promoting template with repo that is not already in target environment fails
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Red Hat Satellite
Classification: Red Hat
Component: Content Management
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: Unspecified
Assignee: Katello Bug Bin
QA Contact: Sachin Ghai
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2012-03-01 16:09 UTC by Ivan Necas
Modified: 2019-09-26 17:45 UTC (History)
7 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2012-05-15 18:55:52 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
Script for reproducing the error (1.31 KB, application/x-shellscript)
2012-03-01 16:09 UTC, Ivan Necas
no flags Details
Stack trace of the error (9.93 KB, text/plain)
2012-03-01 16:10 UTC, Ivan Necas
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHEA-2012:0665 0 normal SHIPPED_LIVE new packages: katello 2012-05-15 22:27:22 UTC

Description Ivan Necas 2012-03-01 16:09:30 UTC
Created attachment 566876 [details]
Script for reproducing the error

Version-Release number of selected component (if applicable):
katello-0.1.300-1

How reproducible:
Always

Steps to Reproduce (see also attached script):
1. create org, env, product, repo
2. promote product to the env
3. create another repo for the product
4. create template
5. add newly created repo to the template
6. promote template to the env
  
Actual results:
[ERROR: 2012-03-01 16:44:36 #11526] wrong number of arguments (1 for 2)
the whole stack trace in attachment
Expected results:
Successful promotion

Comment 1 Ivan Necas 2012-03-01 16:10:09 UTC
Created attachment 566877 [details]
Stack trace of the error

Comment 2 Martin Bacovsky 2012-03-07 12:30:29 UTC
This issue was fixed in commit ccf50f and should be included in katello>=0.2.9

Comment 6 Sachin Ghai 2012-03-19 09:44:03 UTC
verified with following CFSE build.

[root@perceptor ~]# rpm -qa | grep -ie katello-0 -ie katello-cli
katello-0.1.304-1.el6.noarch
katello-cli-common-0.1.105-1.el6.noarch
katello-cli-0.1.105-1.el6.noarch


Now I can successfully promote the system template including the repo which is not in the target env.

[root@perceptor ~]# katello -u admin -p admin shell
katello> org create --name sghai
Successfully created org [ sghai ]
katello> environment create --name test --org sghai --prior Library
Successfully created environment [ test ]
katello> provider create --name custom --org sghai
Successfully created provider [ custom ]
katello> product create --name pulp --provider custom --org sghai
Successfully created product [ pulp ]

Created a repo and promoted to next env:
==========================================
katello> repo create --name pulp_64 --product pulp --org sghai --url http://repos.fedorapeople.org/repos/pulp/pulp/v1/stable/6Server/x86_64/
Successfully created repository [ pulp_64 ]
katello> changeset create --name pulp1 --org sghai --env test 
Successfully created changeset [ pulp1 ] for environment [ test ]
katello> changeset update --name pulp1 --org sghai --env test --add_product pulp
Successfully updated changeset [ pulp1 ]
katello> changeset promote --name pulp1 --org sghai --env test
Changeset [ pulp1 ] promoted               

Created another repo which is not in next target env:
====================================================

katello> repo create --name pulp_86 --product pulp --org sghai --url http://repos.fedorapeople.org/repos/pulp/pulp/v1/stable/6Server/i386/
Successfully created repository [ pulp_86 ]

Created  template:
================
katello> template create --name temp1 --org sghai
Successfully created template [ temp1 ]
katello> template update --name temp1 --org sghai --from_product pulp --add_repository pulp_86
Successfully updated template [ temp1 ] 

Promoted template to next env:
============================= 
katello> changeset create --name pulp2 --org sghai --env test
Successfully created changeset [ pulp2 ] for environment [ test ]
katello> changeset update --name pulp2 --org sghai --env test --add_template temp1
Successfully updated changeset [ pulp2 ]
katello> changeset promote --name pulp2 --org sghai --env test
Changeset [ pulp2 ] promoted               
katello>

Comment 7 errata-xmlrpc 2012-05-15 18:55:52 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

http://rhn.redhat.com/errata/RHEA-2012-0665.html


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