Bug 1092712
Summary: | hammer content-host create should provide better information to required fields | ||
---|---|---|---|
Product: | Red Hat Satellite | Reporter: | Og Maciel <omaciel> |
Component: | Hammer | Assignee: | Dustin Tsang <dtsang> |
Status: | CLOSED CURRENTRELEASE | QA Contact: | sthirugn <sthirugn> |
Severity: | low | Docs Contact: | |
Priority: | unspecified | ||
Version: | 6.0.3 | CC: | bbuckingham, bkearney, daviddavis, jmontleo, mmccune, omaciel, sthirugn |
Target Milestone: | Unspecified | Keywords: | Triaged |
Target Release: | Unused | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
URL: | http://projects.theforeman.org/issues/7025 | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | Bug Fix | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2014-09-11 12:24:04 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: |
Description
Og Maciel
2014-04-29 19:13:10 UTC
hammer> lifecycle-environment list --organization-id ACME_Corporation ---|---------|--------------- ID | NAME | PRIOR ---|---------|--------------- 2 | DEV | id1nameLibrary 1 | Library | 3 | QE | id2nameDEV ---|---------|--------------- hammer> content-host create --name example01.usersys.redhat.com --organization-id ACME_Corporation Could not create content host: undefined method `default_environment' for nil:NilClass hammer> content-host create --name example01.usersys.redhat.com --organization-id ACME_Corporation --environment-id 2 Could not create content host: undefined method `get_content_view_environment_by_cp_id' for #<Katello::Api::V2::SystemsController:0x0000000e864328> h Created redmine issue http://projects.theforeman.org/issues/6453 from this bug Moving to POST since upstream bug http://projects.theforeman.org/issues/6453 has been closed ------------- dustin tsang https://github.com/Katello/hammer-cli-katello/pull/200 ------------- dustin tsang Applied in changeset commit:hammer-cli-katello|6f3b80d64ec1003e38df793f93078759a80f4739. Failed. hammer> content-host create --organization-id=3 --name trialhost1 Could not create content host: undefined method `default_environment' for #<User:0x0000000976af58> Version Tested: GA Snap 4 - Satellite-6.0.4-RHEL-6-20140806.0 * apr-util-ldap-1.3.9-3.el6_0.1.x86_64 * candlepin-0.9.19-1.el6_5.noarch * candlepin-scl-1-5.el6_4.noarch * candlepin-scl-quartz-2.1.5-5.el6_4.noarch * candlepin-scl-rhino-1.7R3-1.el6_4.noarch * candlepin-scl-runtime-1-5.el6_4.noarch * candlepin-selinux-0.9.19-1.el6_5.noarch * candlepin-tomcat6-0.9.19-1.el6_5.noarch * elasticsearch-0.90.10-4.el6sat.noarch * foreman-1.6.0.38-1.el6sat.noarch * foreman-compute-1.6.0.38-1.el6sat.noarch * foreman-gce-1.6.0.38-1.el6sat.noarch * foreman-libvirt-1.6.0.38-1.el6sat.noarch * foreman-ovirt-1.6.0.38-1.el6sat.noarch * foreman-postgresql-1.6.0.38-1.el6sat.noarch * foreman-proxy-1.6.0.23-1.el6sat.noarch * foreman-selinux-1.6.0.4-1.el6sat.noarch * foreman-vmware-1.6.0.38-1.el6sat.noarch * katello-1.5.0-28.el6sat.noarch * katello-ca-1.0-1.noarch * katello-certs-tools-1.5.6-1.el6sat.noarch * katello-installer-0.0.57-1.el6sat.noarch * openldap-2.4.23-34.el6_5.1.x86_64 * pulp-katello-0.3-3.el6sat.noarch * pulp-nodes-common-2.4.0-0.30.beta.el6sat.noarch * pulp-nodes-parent-2.4.0-0.30.beta.el6sat.noarch * pulp-puppet-plugins-2.4.0-0.30.beta.el6sat.noarch * pulp-puppet-tools-2.4.0-0.30.beta.el6sat.noarch * pulp-rpm-plugins-2.4.0-0.30.beta.el6sat.noarch * pulp-selinux-2.4.0-0.30.beta.el6sat.noarch * pulp-server-2.4.0-0.30.beta.el6sat.noarch * python-ldap-2.3.10-1.el6.x86_64 * ruby193-rubygem-net-ldap-0.3.1-3.el6sat.noarch * ruby193-rubygem-runcible-1.1.0-2.el6sat.noarch * sssd-ldap-1.11.5.1-3.el6.x86_64 new redmine issue created because a new root cause. *** Bug 1127734 has been marked as a duplicate of this bug. *** Verified. Step 1: Similar command from bug description and I am asked to provide environment hammer> content-host create --organization-id=3 --name trialhost1 Could not create content host: Organization rhcorp has more than one environment. Please specify target environment for content host registration. Step 2: Providing environment and now it asks me to provide content view hammer> content-host create --organization-id=3 --name trialhost2 --lifecycle-environment=DEV Could not create content host: Error: At least one of options --content-view, --content-view-id is required See: ' content-host create --help' Step 3: Providing content view and all is well now. hammer> content-host create --organization-id=3 --name trialhost2 --lifecycle-environment=DEV --content-view=cv1 Name: trialhost2 ID: 66ef4908-31bc-47c3-a078-9397867aa94e Description: Initial Registration Params Location: None Lifecycle Environment: DEV Content View: cv1 Entitlement Status: valid Release Version: Autoheal: true Content host created Although at the end of Step 1 I should have been asked to provide both environment and content view, but I still get meaningful error messages to carry out the operation. Ok to mark VERIFIED. Version Tested: GA Snap 5 - Satellite-6.0.4-RHEL-6-20140813.2 * apr-util-ldap-1.3.9-3.el6_0.1.x86_64 * candlepin-0.9.23-1.el6_5.noarch * candlepin-common-1.0.1-1.el6_5.noarch * candlepin-scl-1-5.el6_4.noarch * candlepin-scl-quartz-2.1.5-5.el6_4.noarch * candlepin-scl-rhino-1.7R3-1.el6_4.noarch * candlepin-scl-runtime-1-5.el6_4.noarch * candlepin-selinux-0.9.23-1.el6_5.noarch * candlepin-tomcat6-0.9.23-1.el6_5.noarch * elasticsearch-0.90.10-4.el6sat.noarch * foreman-1.6.0.40-1.el6sat.noarch * foreman-compute-1.6.0.40-1.el6sat.noarch * foreman-gce-1.6.0.40-1.el6sat.noarch * foreman-libvirt-1.6.0.40-1.el6sat.noarch * foreman-ovirt-1.6.0.40-1.el6sat.noarch * foreman-postgresql-1.6.0.40-1.el6sat.noarch * foreman-proxy-1.6.0.27-1.el6sat.noarch * foreman-selinux-1.6.0.6-1.el6sat.noarch * foreman-vmware-1.6.0.40-1.el6sat.noarch * katello-1.5.0-28.el6sat.noarch * katello-ca-1.0-1.noarch * katello-certs-tools-1.5.6-1.el6sat.noarch * katello-installer-0.0.59-1.el6sat.noarch * openldap-2.4.23-34.el6_5.1.x86_64 * openldap-devel-2.4.23-34.el6_5.1.x86_64 * pulp-katello-0.3-3.el6sat.noarch * pulp-nodes-common-2.4.0-0.30.beta.el6sat.noarch * pulp-nodes-parent-2.4.0-0.30.beta.el6sat.noarch * pulp-puppet-plugins-2.4.0-0.30.beta.el6sat.noarch * pulp-puppet-tools-2.4.0-0.30.beta.el6sat.noarch * pulp-rpm-plugins-2.4.0-0.30.beta.el6sat.noarch * pulp-selinux-2.4.0-0.30.beta.el6sat.noarch * pulp-server-2.4.0-0.30.beta.el6sat.noarch * python-ldap-2.3.10-1.el6.x86_64 * ruby193-rubygem-net-ldap-0.3.1-3.el6sat.noarch * ruby193-rubygem-runcible-1.1.0-2.el6sat.noarch @Og: Can you please review my Comment 11 and let me know if you are okay with this behavior. This was delivered with Satellite 6.0 which was released on 10 September 2014. |