Bug 888138
| Summary: | SAM Cli : Applying default custom info keynames to all existing org failed | ||
|---|---|---|---|
| Product: | [Retired] Subscription Asset Manager | Reporter: | Tazim Kolhar <tkolhar> |
| Component: | katello | Assignee: | Adam Price <adprice> |
| Status: | CLOSED WORKSFORME | QA Contact: | Og Maciel <omaciel> |
| Severity: | medium | Docs Contact: | |
| Priority: | unspecified | ||
| Version: | 1.2 | CC: | cwelton, omaciel, tomckay |
| Target Milestone: | rc | ||
| Target Release: | --- | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | Doc Type: | Bug Fix | |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2013-01-15 20:43:36 UTC | Type: | Bug |
| 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: | 833466 | ||
Tazim, you have to add default system info to an org before you can apply them to existing systems.
example:
1. I have 4 existing systems within org 'acme'
2. I want all my systems in org 'acme' to have a custom info key of 'asset-tag'
3. I add 'asset-tag' to org 'acme'
$ katello org add_default_system_info --name=acme --keyname="asset-tag"
4. I then apply this custom info to all existing systems
$ katello org apply_default_system_info --name=acme
works4me sam> org list
---------------------------------------------------------------------------------------------------------------------
Organization List
Id Name Label Description
---------------------------------------------------------------------------------------------------------------------
5 SAM QE SAM_QE
2 São Paulo 9b8f7e32-b818-4d49-854a-7cf3abf1b3fb
1 ACME_Corporation ACME_Corporation ACME_Corporation Organization
sam> org add_default_system_info --name 'São Paulo' --keyname 'asset-tag'
Successfully added default custom info key [ asset-tag ] to Org [ São Paulo ]
sam> org apply_default_system_info --name 'São Paulo'
Successfully applied default custom info keys to [ 5 ] systems in Org [ São Paulo ]
sam>
Works for me with the following build: * candlepin-0.7.23-1.el6_3.noarch * candlepin-tomcat6-0.7.23-1.el6_3.noarch * elasticsearch-0.19.9-5.el6_3.noarch * katello-candlepin-cert-key-pair-1.0-1.noarch * katello-certs-tools-1.2.1-1h.el6_3.noarch * katello-cli-1.2.1-11h.el6_3.noarch * katello-cli-common-1.2.1-11h.el6_3.noarch * katello-common-1.2.1-12h.el6_3.noarch * katello-configure-1.2.3-1h.el6_3.noarch * katello-glue-candlepin-1.2.1-12h.el6_3.noarch * katello-headpin-1.2.1-12h.el6_3.noarch * katello-headpin-all-1.2.1-12h.el6_3.noarch * katello-selinux-1.2.1-2h.el6_3.noarch * thumbslug-0.0.28-1.el6_3.noarch * thumbslug-selinux-0.0.28-1.el6_3.noarch |
Description of problem: Added default custom info keynames for a Organisation tried applying default custom info keys to the existing Org it failed Version-Release number of selected component (if applicable): # rpm -qa | grep katello katello-selinux-1.2.1-1h.el6_3.noarch katello-cli-1.2.4-4h.el6_3.noarch katello-headpin-1.2.6-6h.el6_3.noarch katello-certs-tools-1.2.1-1h.el6_3.noarch katello-candlepin-cert-key-pair-1.0-1.noarch katello-configure-1.2.3-1h.el6_3.noarch katello-common-1.2.6-6h.el6_3.noarch katello-headpin-all-1.2.6-6h.el6_3.noarch katello-glue-candlepin-1.2.6-6h.el6_3.noarch katello-cli-common-1.2.4-4h.el6_3.noarch How reproducible: # yum install -y katello-headpin-all # katello-configure --deployment=sam Steps to Reproduce: 1.# headpin -u admin -p admin org info --name ACME_Corporation -------------------------------------------------------------------------------- Organization Information -------------------------------------------------------------------------------- Id : 1 Name : ACME_Corporation Description: ACME_Corporation Organization Available Service Levels: Default System Info Keys: [ test_msg ] 2.# headpin -u admin -p admin org apply_default_system_info --name ACME_Corporation No default custom info keys to apply in Org [ ACME_Corporation ] Actual results: unable to detect the default custon info keys. Expected results: the default custom info keys should be applied. Additional info: