GET /api/v2/discovered_hosts
Llista tots els amfitrions descoberts

Params

Param Name Description
search
Optional

filtra els resultats


Value:

Must be String

order
Optional

ordena els resultats


Value:

Must be String

page
Optional

pagina els resultats


Value:

Must be String

per_page
Optional

Nombre d'entrades per petició


Value:

Must be String


GET /api/v2/discovered_hosts/:id
Show a discovered host

Params

Param Name Description
id
Required

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, dot(.), space, underscore(_), hypen(-) with no leading or trailing space.


POST /api/v2/discovered_hosts
Crea un amfitrió descobert per a provar-ho (utilitzeu /facts per crear nous amfitrions)

Params

Param Name Description
discovered_host
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a Hash

discovered_host[name]
Required

Value:

Must be String

discovered_host[ip]
Required

Value:

Must be String

discovered_host[mac]
Required

Value:

Must be String


PUT /api/v2/discovered_hosts/:id
Provision a discovered host

Params

Param Name Description
id
Required

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.

discovered_host
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a Hash

discovered_host[name]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be String

discovered_host[environment_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be String

discovered_host[ip]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

not required if using a subnet with DHCP proxy


Value:

Must be String

discovered_host[mac]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

not required if it's a virtual machine


Value:

Must be String

discovered_host[architecture_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[domain_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[puppet_proxy_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[puppet_class_ids]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be an array of any type

discovered_host[operatingsystem_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be String

discovered_host[medium_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[ptable_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[subnet_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[sp_subnet_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[model_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[hostgroup_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[owner_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[puppet_ca_proxy_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[image_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be a number.

discovered_host[host_parameters_attributes]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be an array of any type

discovered_host[build]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be 'true' or 'false'

discovered_host[enabled]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be 'true' or 'false'

discovered_host[provision_method]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be String

discovered_host[managed]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be 'true' or 'false'

discovered_host[progress_report_id]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

UUID to track orchestration tasks status, GET /api/orchestration/:UUID/tasks


Value:

Must be String

discovered_host[capabilities]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

Value:

Must be String

discovered_host[root_pass]
Optional , <span class="translation_missing" title="translation missing: ca.apipie.nil_allowed">Nil Allowed</span>

required if value is not inherited from host group or default password in settings


Value:

Must be String


DELETE /api/v2/discovered_hosts/:id
Delete a discovered host

Params

Param Name Description
id
Required

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.


POST /api/v2/discovered_hosts/facts
Puja els objectes d'interès per un amfitrió, creant el nou amfitrió si fos necessari

Params

Param Name Description
facts
Required

hash containing facts for the host with minimum set of facts: discovery_bootif, macaddress_eth0, ipaddress, ipaddress_eth0, interfaces: eth0 (example in case primary interface is named eth0)


Value:

Must be Hash


POST /api/v2/discovered_hosts/:id/auto_provision
Execute rules against a discovered host

Params

Param Name Description
id
Required

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.


POST /api/v2/discovered_hosts/auto_provision_all
Execute rules against all currently discovered hosts


PUT /api/v2/discovered_hosts/:id/refresh_facts
S'estan refrescant els objectes d'interès d'un amfitrió descobert

Params

Param Name Description
id
Required

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.


PUT /api/v2/discovered_hosts/:id/reboot
Rebooting a discovered host

Params

Param Name Description
id
Required

Value:

Must be an identifier, string from 1 to 128 characters containing only alphanumeric characters, space, underscore(_), hypen(-) with no leading or trailing space.


PUT /api/v2/discovered_hosts/reboot_all
Rebooting all discovered hosts