# Description

An environment is a basic organization structure that groups hosts, products, repositories, etc. Every host belongs to one environment and it's isolated inside so that it can see only content that is in its environment.

## Chains

Environments are ordered into chains and their content (products, repositories, tempaltes, packages) can be moved to an environment only from its prior environment. You can have for example chain like:

Library -> Development -> Testing -> Production

Each change in an environment is done through a changeset in an action called promotion.

## Library

Library is a special environment that has no ascendant: All the content starts in this environment. More chains can start from the library environment but no further branching of a chain is enabled.


GET /katello/api/environments
Listar ambientes em uma organização

GET /katello/api/organizations/:organization_id/environments
Listar ambientes em uma organização

Parâmentros

Nome parâmetro Descrição
organization_id
opcional

identificador da organização

Validations:

  • Must be a number.

library
opcional

definir verdadediro se você desejar ver somente os ambientes de biblioteca

Validations:

  • Must be one of: true, false.

name
opcional

filstrar somente ambientes contendo este nome

Validations:

  • String

search
opcional

Buscar faixa

Validations:

  • String

page
opcional

Número de página, iniciando em 1

Validations:

  • Must be a number.

per_page
opcional

Número de resultados por página para retornar

Validations:

  • Must be a number.

order
opcional

Sort field and order, eg. 'id DESC'

Validations:

  • String

full_result
opcional

Se deve ou não exibir todos os resultados

Validations:

  • Must be one of: true, false, 1, 0

sort
opcional

Versão Hash de param de “ordem”

Validations:

  • Hash

sort[by]
opcional

Campo para classificar os resultados

Validations:

  • String

sort[order]
opcional

Como encomendar os resultados classificados (por exemplo ASC para ascendente)

Validations:

  • String


GET /katello/api/environments/:id
Mostrar um ambiente

GET /katello/api/organizations/:organization_id/environments/:environment_id
Mostrar um ambiente

Parâmentros

Nome parâmetro Descrição
id
requerido

ID de ambiente

Validations:

  • Must be a number.

organization_id
opcional

ID da organização

Validations:

  • Must be a number.


POST /katello/api/environments
Criar um ambiente

POST /katello/api/organizations/:organization_id/environments
Criar um ambiente em uma organização

Parâmentros

Nome parâmetro Descrição
organization_id
requerido

nome da organização

Validations:

  • Must be a number.

name
requerido

nome do ambiente

Validations:

  • String

label
opcional

rotular o ambiente

Validations:

  • String

description
opcional

descrição do ambiente

Validations:

  • String

registry_name_pattern
opcional

pattern for container image names

Validations:

  • String

registry_unauthenticated_pull
opcional

allow unauthenticed pull of container images

Validations:

  • Must be one of: true, false, 1, 0

prior_id
requerido

ID of an environment that is prior to the new environment in the chain. It has to be either the ID of Library or the ID of an environment at the end of a chain.

Validations:

  • Integer


PUT /katello/api/environments/:id
Atualizar um ambiente

PUT /katello/api/organizations/:organization_id/environments/:id
Atualizar um ambiente em uma organização

Parâmentros

Nome parâmetro Descrição
id
requerido

ID de ambiente

Validations:

  • Must be a number.

organization_id
opcional

nome da organização

Validations:

  • Must be a number.

new_name
opcional

novo nome a ser fornecido ao ambiente

Validations:

  • String

description
opcional

descrição do ambiente

Validations:

  • String

registry_name_pattern
opcional

pattern for container image names

Validations:

  • String

registry_unauthenticated_pull
opcional

allow unauthenticed pull of container images

Validations:

  • Must be one of: true, false, 1, 0

async
opcional

Do not wait for the update action to finish. Default: true

Validations:

  • Must be one of: true, false, 1, 0


DELETE /katello/api/environments/:id
Destruir um ambiente

DELETE /katello/api/organizations/:organization_id/environments/:id
Destruir um ambiente em uma organização

Parâmentros

Nome parâmetro Descrição
id
requerido

ID de ambiente

Validations:

  • Must be a number.

organization_id
opcional

identificador da organização

Validations:

  • Must be a number.


GET /katello/api/organizations/:organization_id/environments/paths
Listar caminhos de ambiente

Parâmentros

Nome parâmetro Descrição
organization_id
opcional

identificador da organização

Validations:

  • Must be a number.

permission_type
opcional

The associated permission type. One of (readable | promotable) Default: readable

Validations:

  • String