Chapter 7. Containers Providers
A containers provider is a service that manages container resources, that can be added to the Red Hat CloudForms appliance.
CloudForms can connect to OpenShift Container Platform containers providers and manage them similarly to infrastructure and cloud providers. This allows you to gain control over different aspects of your containers environment and answer questions such as:
- How many containers exist in my environment?
- Does a specific node have enough resources?
- How many distinct images are used?
- Which image registries are used?
When CloudForms connects to a container’s environment, it collects information on different areas of the environment:
- Entities such as pods, nodes, or services.
- Basic relationships between the entities, for example: Which services are serving which pods?
- Advanced insight into relationships, for example: Which two different containers are using the same image?
- Additional information, such as events, projects, routes, and metrics.
You can manage policies for containers entities by adding tags. All containers entities except volumes can be tagged.
This chapter provides details on managing containers providers. For details on working with the resources within a container environment, see Container Entities in Managing Infrastructure and Inventory.
The CloudForms user interface uses virtual thumbnails to represent containers providers. Each thumbnail contains four quadrants by default, which display basic information about each provider:
- Number of nodes
- Container provider software
- Power state
- Authentication status
Table 7.1. Containers provider authentication status
| Icon | Description |
|---|---|
|
| Validated: Valid authentication credentials have been added. |
|
| Invalid: Authentication credentials are invalid. |
|
| Unknown: Authentication status is unknown or no credentials have been entered. |
7.1. Obtaining an OpenShift Container Platform Management Token
When deploying OpenShift using openshift-ansible-3.0.20 (or later versions), the OpenShift Container Platform service account and roles required by Red Hat CloudForms are installed by default.
See the OpenShift Container Platform documentation for a list of the default roles.
Run the following to obtain the token needed to add an OpenShift Container Platform provider:
# oc sa get-token -n management-infra management-admin eyJhbGciOiJSUzI1NiI...
7.2. Enabling OpenShift Cluster Metrics
Use the OpenShift Cluster Metrics plug-in to collect node, pod, and container metrics into one location. This helps track usage and find common issues.
- Configure Red Hat CloudForms to allow for all three Capacity & Utilization server roles.
- Enable cluster metrics using the OpenShift Container Platform documentation.
7.3. Adding an OpenShift Container Platform Provider
After initial installation and creation of a Red Hat CloudForms environment, add an OpenShift Container Platform provider using the token obtained in Section 7.1, “Obtaining an OpenShift Container Platform Management Token” and following the procedure below.
- Navigate to → → .
-
Click
(Configuration), then click
(Add Existing Containers Provider).
- Enter a Name for the provider.
- From the Type list, select OpenShift Container Platform.
-
Enter the appropriate Zone for the provider. If you do not specify a zone, it is set to
default. Under Endpoints in the Default tab, configure the following for the OpenShift provider:
Select a Security Protocol method to specify how to authenticate the provider:
- SSL: Authenticate the provider securely using a trusted Certificate Authority. Select this option if the provider has a valid SSL certificate and it is signed by a trusted Certificate Authority. No further configuration is required for this option.
SSL trusting custom CA: Authenticate the provider with a self-signed certificate. For this option, copy your provider’s CA certificate to the Trusted CA Certificates box in PEM format.
NoteTo obtain your OpenShift Container Platform provider’s CA certificate, run the
oc get secretcommand on your provider, substituting values for your provider and token as needed. To obtain a token for your provider, see Section 7.1, “Obtaining an OpenShift Container Platform Management Token”.For example:
# oc get secret --namespace management-infra management-admin-token-8ixxs --template='{{index .data "ca.crt"}}' | base64 --decodePaste the output (a block of text starting with
-----BEGIN CERTIFICATE-----) into the Trusted CA Certificates field.- SSL without validation: Authenticate the provider insecurely (not recommended).
Enter the Hostname or IPv4 or IPv6 address of the provider.
ImportantThe Hostname must use a unique fully qualified domain name.
-
Enter the API Port of the provider. The default port is
8443. - Enter the OpenShift management token in the Token field. This is the token obtained earlier in Section 7.1, “Obtaining an OpenShift Container Platform Management Token”.
- Enter the same token in the Confirm Token field.
- Click Validate to confirm that Red Hat CloudForms can connect to the OpenShift Container Platform provider.
Under Endpoints in the Hawkular tab, configure the following for Hawkular capacity and utilization metrics collection:
Select a Security Protocol method to specify how to authenticate the provider:
- SSL: Authenticate the provider securely using a trusted Certificate Authority. Select this option if the provider has a valid SSL certificate and it is signed by a trusted Certificate Authority. No further configuration is required for this option.
SSL trusting custom CA: Authenticate the provider with a self-signed certificate. For this option, copy your provider’s CA certificate to the Trusted CA Certificates box in PEM format.
NoteIn OpenShift, the default deployment of the router generates certificates during installation, which can be used with the SSL trusting custom CA option. Connecting a Hawkular endpoint with this option requires the CA certificate that the cluster uses for service certificates, which is stored in
/etc/origin/master/service-signer.crton the first master in a cluster. You can also obtain the certificate from the cluster by running the following on your provider:# oc get secrets $(oc get secrets -n default -o jsonpath='{.items[?(@.type=="kubernetes.io/service-account-token")].metadata.name}{"\n"}' | grep -Eo "router.+" | awk '{print $1}') -n default -o jsonpath='{.data.ca\.crt}{"\n"}' | base64 -d- SSL without validation: Authenticate the provider insecurely using SSL. (Not recommended)
- Enter the Hostname or IPv4 or IPv6 address of the provider.
-
Enter the API Port if your Hawkular provider uses a non-standard port for access. The default port is
443. - Click Validate to confirm that Red Hat CloudForms can connect to the Hawkular endpoint.
- Click Add.
7.4. Tagging Containers Providers
Apply tags to all containers providers to categorize them together at the same time.
- Navigate to → → .
- Select the checkboxes for the containers providers to tag.
-
Click
(Policy), and then
(Edit Tags).
Select a tag to assign from the drop-down menu.
- Select a value to assign.
- Click Save.
7.5. Removing Containers Providers
You may want to remove a containers provider from the VMDB if the provider is no longer in use.
- Navigate to → → .
- Select the checkboxes for the containers providers to remove.
-
Click
(Configuration), and then
(Remove Containers Providers from the VMDB).
- Click OK.
7.6. Editing a Containers Provider
Edit information about a provider such as the name, hostname, IP address or port, and credentials.
- Navigate to → → .
- Click the containers provider to edit.
-
Click
(Configuration), and then
(Edit Selected Containers Provider).
Edit the Basic Information. This varies depending on the Type of provider.
NoteThe Type value is unchangeable.
To use a different containers provider, create a new one.
- Edit the Credentials by typing in a new Token.
- Click Validate and wait for notification of successful validation.
- Click Save.
7.7. Viewing a Containers Provider’s Timeline
View the timeline of events for instances registered to a containers provider.
- Navigate to → → .
- Click the desired containers provider for viewing the timeline.
-
Click
(Monitoring), and then
(Timelines).
From Options, customize the period of time to display and the types of events to see.
- Use Show to select regular Management Events or Policy Events.
- Use the Interval dropdown to select hourly or daily data points.
- Use Date to type the date for the timeline to display.
- If you select to view a daily timeline, use Show to set how many days back to go. The maximum history is 31 days.
- From the Level dropdown, select a Summary event, or a Detail list of events.
- The three Event Groups dropdowns allow you to select different groups of events to display. Each has its own color.
Click on an item for more detailed information.




Where did the comment section go?
Red Hat's documentation publication system recently went through an upgrade to enable speedier, more mobile-friendly content. We decided to re-evaluate our commenting platform to ensure that it meets your expectations and serves as an optimal feedback mechanism. During this redesign, we invite your input on providing feedback on Red Hat documentation via the discussion platform.