If you have a content view in library published few times and promoted a few times hammer repo list --organization-id=1 will return all repos across all content views and environments. Meaning it will return repos with the same name 10 or 20 times. Ideal behaviour would be to say something along the lines of "If you dont pass me an environment I am going to assume library/default content view version."
Created from redmine issue http://projects.theforeman.org/issues/6026
Upstream bug assigned to paji
[root@qeblade35 ~]# hammer -v -p changeme organization list ---|----------------------|----------------------|---------------------------------- ID | NAME | LABEL | DESCRIPTION ---|----------------------|----------------------|---------------------------------- 3 | Bugzilla | Bugzilla | 1 | Default_Organization | Default_Organization | Default_Organization Organization 4 | DogFood | DogFood | ---|----------------------|----------------------|---------------------------------- [root@qeblade35 ~]# hammer -v -p changeme repository list --organization-id=1 No data. [root@qeblade35 ~]# hammer -v -p changeme repository list --organization-id=3 ---|---------|---------|--------------|--------------------------------------------- ID | NAME | PRODUCT | CONTENT TYPE | URL ---|---------|---------|--------------|--------------------------------------------- 1 | WannaBe | Foo Bar | yum | https://omaciel.fedorapeople.org/fakerepo01/ ---|---------|---------|--------------|--------------------------------------------- [root@qeblade35 ~]# hammer -v -p changeme repository list --organization-id=4 ---|---------|---------|--------------|--------------------------------------------- ID | NAME | PRODUCT | CONTENT TYPE | URL ---|---------|---------|--------------|--------------------------------------------- 7 | HasBeen | Google | yum | https://omaciel.fedorapeople.org/fakerepo02/ ---|---------|---------|--------------|---------------------------------------------
I should have mentioned that each content view was published and promoted a few times: [root@qeblade35 ~]# hammer -v -p changeme content-view info --id 4 --organization-id 3 ID: 4 Name: WannaBeCV Label: WannaBeCV Composite: Description: Organization: Bugzilla Repositories: 1) ID: 1 Name: WannaBe Label: WannaBe Puppet Modules: Environments: 1) ID: 4 Name: DEV 2) ID: 2 Name: Library Versions: 1) ID: 4 Version: 1 Published: 2014/07/29 15:54:31 2) ID: 5 Version: 2 Published: 2014/07/29 15:56:03 3) ID: 6 Version: 3 Published: 2014/07/29 17:29:51 Components: [root@qeblade35 ~]# hammer -v -p changeme content-view info --id 4 --organization-id 4 ID: 4 Name: WannaBeCV Label: WannaBeCV Composite: Description: Organization: Bugzilla Repositories: 1) ID: 1 Name: WannaBe Label: WannaBe Puppet Modules: Environments: 1) ID: 4 Name: DEV 2) ID: 2 Name: Library Versions: 1) ID: 4 Version: 1 Published: 2014/07/29 15:54:31 2) ID: 5 Version: 2 Published: 2014/07/29 15:56:03 3) ID: 6 Version: 3 Published: 2014/07/29 17:29:51 Components:
Verified: Environment: * Build: Satellite-6.0.4-RHEL-6-20140723.0 Packages: * 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.32-1.el6sat.noarch * foreman-compute-1.6.0.32-1.el6sat.noarch * foreman-gce-1.6.0.32-1.el6sat.noarch * foreman-libvirt-1.6.0.32-1.el6sat.noarch * foreman-ovirt-1.6.0.32-1.el6sat.noarch * foreman-postgresql-1.6.0.32-1.el6sat.noarch * foreman-proxy-1.6.0.22-1.el6sat.noarch * foreman-selinux-1.6.0.3-1.el6sat.noarch * foreman-vmware-1.6.0.32-1.el6sat.noarch * katello-1.5.0-27.el6sat.noarch * katello-ca-1.0-1.noarch * katello-certs-tools-1.5.6-1.el6sat.noarch * katello-installer-0.0.56-1.el6sat.noarch * openldap-2.4.23-32.el6_4.1.x86_64 * pulp-katello-0.3-3.el6sat.noarch * pulp-nodes-common-2.4.0-0.23.beta.el6sat.noarch * pulp-nodes-parent-2.4.0-0.23.beta.el6sat.noarch * pulp-puppet-plugins-2.4.0-0.23.beta.el6sat.noarch * pulp-puppet-tools-2.4.0-0.23.beta.el6sat.noarch * pulp-rpm-plugins-2.4.0-0.23.beta.el6sat.noarch * pulp-selinux-2.4.0-0.23.beta.el6sat.noarch * pulp-server-2.4.0-0.23.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 * rubygem-hammer_cli-0.1.1-10.el6sat.noarch * rubygem-hammer_cli_foreman-0.1.1-13.el6sat.noarch * rubygem-hammer_cli_foreman_tasks-0.0.3-3.el6sat.noarch * rubygem-hammer_cli_katello-0.0.4-9.el6sat.noarch
This was delivered with Satellite 6.0 which was released on 10 September 2014.