3.3. Life Cycle Environments

Application life cycles are divided into life cycle environments, which represent each stage of the application life cycle. Life cycle environments are linked to form an environment path. You can promote content along the environment path to the next life cycle environment when required. For example, if development ends on a particular version of an application, you can promote this version to the testing environment and start development on the next version.
An environment path containing four environments, including the base Library environment.

Figure 3.2. An Environment Path Containing Four Environments

3.3.1. Creating Life Cycle Environments

This procedure describes how to create a life cycle environment in Red Hat Satellite.

Procedure 3.10. To Create a Life Cycle Environment:

  1. Select an organization from the menu in the top left hand corner.
  2. Click ContentLife Cycle Environments and then click New Environment Path.
  3. Insert a name and a label (automatically fills in the Name field input) for the life cycle environment. The Description field is optional.
  4. Click Save to create the environment.

3.3.2. Adding Life Cycle Environments to a Red Hat Satellite Capsule Server

If a newly created Red Hat Satellite Capsule Server has content functionality enabled, the Capsule Server needs an environment added to enable it to synchronize content from the Satellite Server and provide content to host systems.

Important

The Satellite Capsule Server is configured through the Satellite Server's command line interface (CLI). Execute all hammer commands on the Satellite Server.

Procedure 3.11. To Add Environments to the Satellite Capsule Server:

  1. Log in to the Satellite Server CLI as root.
  2. Choose the desired Red Hat Satellite Capsule Server from the list and take note of its id:
    # hammer capsule list
    
    The Satellite Capsule Server's details can be verified using the command:
    # hammer capsule info --id capsule_id_number
  3. Verify the list of life cycle environments available for the Red Hat Capsule Server and note down the environment id:
    # hammer capsule content available-lifecycle-environments --id capsule_id_number
    Where:
    • available-lifecycle-environments are life cycle environments that are available to the Satellite Capsule but are currently not attached to the Satellite Capsule.
  4. Add the life cycle environment to the Satellite Capsule Server:
    # hammer capsule content add-lifecycle-environment --id capsule_id_number --environment-id environment_id_number
    Where:
    • capsule_id_number stands for the Satellite Capsule Server's identification number.
    • environment_id_number stands for the life cycle environment's identification number.
    Repeat this step for every life cycle environment to be added to the Capsule Server.
  5. Synchronize the content from the Satellite Server's environment to the Satellite Capsule Server:
    # hammer capsule content synchronize --id capsule_id_number
    When an external Satellite Capsule Server has various life cycle environments, and only one life cycle environment needs to be synchronized, it is possible to target a specific environment by specifying the environment identification number:
    # hammer capsule content synchronize --id external_capsule_id_number --environment-id environment_id_number

3.3.3. Promoting Content Views

After you have created a Content View and an environment path consisting of two or more life cycle environments, you can promote the Content View from one environment to the next as required. This means that the most recent version of the Content View that exists in a specified environment will be promoted, or copied, to the next environment in the life cycle environment path.
You can promote a Content View to any environment where that version does not exist. The system automatically suggests the next environment in the life cycle environment path, but you can override this and promote to a different environment if required.

Procedure 3.12. To Promote a Content View:

  1. On the main menu, click ContentContent Views.
  2. In the Name column, click the name of the Content View that you want to promote.
  3. On the Versions tab, identify the latest version, and click Promote.
  4. Identify the promotion path where you want to promote the Content View, select the appropriate life cycle environment, and click Promote Version.
  5. After the promotion has completed, the Versions tab updates to display the new status of your Content Views.

3.3.4. Removing Life Cycle Environments From Satellite Server

This procedure describes how to remove a life cycle environment from Red Hat Satellite.

Procedure 3.13. To Remove a Life Cycle Environment:

  1. On the main menu, click ContentLife Cycle Environments.
  2. Click the name of the life cycle environment that you want to remove, and then click Remove Environment.
  3. In the confirmation dialog box, click Remove to remove the environment.

Note

You can only delete the latest environment in an environment path. For example, if three environments exist in the order Library, Dev, and Prod, you need to delete Prod before you can delete Dev. You cannot delete the Library environment.

3.3.5. Removing Life Cycle Environments from Capsule Server

There are multiple reasons to remove life cycle environments from Capsule Server. For example:
  • When life cycle environments are no longer relevant to the host systems
  • When life cycle environments have been incorrectly added to Capsule Server

Procedure 3.14. To remove a life cycle environment from Capsule Server:

  1. Log in to the Satellite Server CLI as the root user.
  2. Choose the desired Capsule Server from the list and take note of its id:
    # hammer capsule list
    The Capsule Server's details can be verified using the command:
    # hammer capsule info --id capsule_id_number
  3. Verify the list of life cycle environments currently attached to the Capsule Server and take note of the environment id:
    # hammer capsule content lifecycle-environments --id capsule_id_number
  4. Remove the life cycle environment from Capsule Server:
    # hammer capsule content remove-lifecycle-environment --id capsule_id_number --environment-id environment_id
    Where:
    • capsule_id_number is Capsule Server's identification number.
    • environment_id is the life cycle environment's identification number.
    Repeat this step for every life cycle environment to be removed from the Capsule Server.
  5. Synchronize the content from the Satellite Server's environment to Capsule Server:
    # hammer capsule content synchronize --id capsule_id_number