Connect to IBM Cloud Container Registry
You can connect Harness to IBM Cloud Container Registry using a Harness Docker Registry Connector. The Connector uses your credentials to your IBM Cloud Container Registry and allows you to push and pull images.
This topic explains how to use the Harness Docker Registry Connector to connect Harness to the IBM Cloud Container Registry.
Before you begin
Review: Managing IAM Policies in IBM Cloud
If the IBM Cloud IAM role used by your Docker Registry Connector does not have the policies required by the IBM service you want to access, you can modify or switch the role.
To set up and manage IAM policies, see Defining access role policies.
When you switch or modify the IAM role, it might take up to 5 minutes to take effect.
Supported Platforms and Technologies
For a list of the platforms and technologies supported by Harness, see Supported Platforms and Technologies.
Step 1: Generate an API Key in IBM Cloud Console
Follow the instructions outlined in Creating an API Key from IBM.
Once the API key is successfully generated, click Copy or Download the API key.
Step 2: Create a Docker Registry Connector in Harness
You can create the Docker Registry Connector at the Harness Account, Organisation, or Project level. In this example, we'll use a Project.
Open a Harness Project.
In Project Setup, click Connectors.
Click New Connector, and under Artifact Repositories click Docker Registry.
The Docker Registry Connector settings appear.
In Name, enter a name for this connector.
Harness automatically creates the corresponding Id (entity identifier).
Step 3: Enter Credentials
Here is where you'll use the API key you generated in IBM Cloud.
Select or enter the following options:
|Docker Registry URL||Enter the IBM Cloud Container Registry API endpoint URL. For example:|
|Provider Type||Select Other (Docker V2 compliant)|
|Authentication||Select Username and Password|
|Password||In Password, click Create or Select a Secret.In the new Secret in Secret Value, enter the API key generated in Step 1.|
Click Save, and Continue.
Step 4: Set Up Delegates
Harness uses Docker Registry Connectors at Pipeline runtime to authenticate and perform operations with IBM Cloud Registry. Authentications and operations are performed by Harness Delegates.
You can select Any Available Harness Delegate and Harness will select the Delegate. For a description of how Harness picks Delegates, see Delegates Overview.
You can use Delegate Tags to select one or more Delegates. For details on Delegate Tags, see Select Delegates with Tags.
If you need to install a Delegate, see Delegate Installation Overview.
The Delegate(s) you use must have networking connectivity to the IBM Cloud Container Registry.
Click Save and Continue.
Step 5: Verify Test Connection
Harness tests the credentials you provided using the Delegates you selected.
If the credentials fail, you'll see an error. Click Edit Credentials to modify your credentials.