Project

General

Profile

Actions

Feature #3497

closed

Resource create/update should provide option to associate Orgs

Added by Dominic Cleal over 10 years ago. Updated over 7 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Proxy
Target version:
-
Difficulty:
Triaged:
Team Backlog:
Fixed in Releases:
Found in Releases:
In Kanboard:

Description

Description of problem:
In the UI, we can associate organization with a proxy. There does not appear to be a way to do that in the CLI, however. Would be nice to have.

Something like

hammer -u admin -p admin proxy create --name foobar --url https://example.com:9090 --add_org org_name
hammer -u admin -p admin proxy create --name foobar --url https://example.com:9090 --remove_org org_name
hammer -u admin -p admin proxy update --name foobar --remove_org org_name
hammer -u admin -p admin proxy update --name foobar --remove_org org_name

and even possibly comma-separated, e.g.,

--add_org NorthAmerica,EMEA,APAC

(https://bugzilla.redhat.com/show_bug.cgi?id=1023147)


Related issues 1 (0 open1 closed)

Related to Hammer CLI - Feature #2844: Associating resources with locations and orgsClosedTomáš Strachota07/25/2013Actions
Actions #1

Updated by Dominic Cleal over 10 years ago

It's possible to do this via the organization/location subcommands, but I don't think you can through the resource being associated.

Actions #2

Updated by Dominic Cleal over 10 years ago

  • Related to Feature #2844: Associating resources with locations and orgs added
Actions #3

Updated by Tomáš Strachota over 7 years ago

  • Category changed from Foreman commands (obsolete) to Proxy
  • Status changed from New to Closed

Closing, current release hammer provides standard associating options and commands for proxies:

[~|vm 2.3]hammer proxy create -h
Usage:
    hammer proxy create [OPTIONS]

Options:
 --download-policy DOWNLOAD_POLICY   Download Policy of the capsule, must be one of immediate, on_demand, background, inherit
 --location-ids LOCATION_IDS         REPLACE locations with given ids
                                     Comma separated list of values.
 --locations LOCATION_NAMES          Comma separated list of values.
 --name NAME                          
 --organization-ids ORGANIZATION_IDS REPLACE organizations with given ids.
                                     Comma separated list of values.
 --organizations ORGANIZATION_NAMES  Comma separated list of values.
 --url URL                            
 -h, --help                          print help
[~|vm 2.3]hammer proxy update -h                                                                                                                                                                                   
Usage:
    hammer proxy update [OPTIONS]

Options:
 --download-policy DOWNLOAD_POLICY   Download Policy of the capsule, must be one of immediate, on_demand, background, inherit
 --id ID                              
 --location-ids LOCATION_IDS         REPLACE locations with given ids
                                     Comma separated list of values.
 --locations LOCATION_NAMES          Comma separated list of values.
 --name NAME                         Name to search by
 --new-name NEW_NAME                  
 --organization-ids ORGANIZATION_IDS REPLACE organizations with given ids.
                                     Comma separated list of values.
 --organizations ORGANIZATION_NAMES  Comma separated list of values.
 --url URL                            
 -h, --help                          print help

[~|vm 2.3]hammer organization -h | grep proxy
 add-smart-proxy               Associate a smart proxy
 remove-smart-proxy            Disassociate a smart proxy

[~|vm 2.3]hammer --version
hammer (0.8.0)
 * hammer_cli_foreman (0.8.0)
 * hammer_cli_foreman_tasks (0.0.10)
 * hammer_cli_katello (0.0.26)
Actions

Also available in: Atom PDF