copyright | lastupdated | keywords | subcollection | ||
---|---|---|---|---|---|
|
2022-11-05 |
schematics agents connect, connect agent, register agent |
schematics |
{{site.data.keyword.attribute-definition-list}}
{{site.data.keyword.bpshort}} Agents is a beta feature that is available for evaluation and testing purposes. It is not intended for production usage. Refer to the list of limitations for Agent in the Beta release.
{: #register-agent}
You have successfully set up the {{site.data.keyword.bpshort}} Agents infrastructure and Agents services, the next step is to connect or register your Agent. So that, the {{site.data.keyword.bpshort}} knows about Agent and connect the service instance to it. The diagram depicts the complete {{site.data.keyword.bpshort}} Agents set up flow. {: shortdesc}
{: caption="{{site.data.keyword.bpshort}} Agents set up" caption-side="center"}
{: #register-ui} {: ui}
-
Log in to your {{site.data.keyword.cloud_notm}}{: external} account by using your credentials.
-
Navigate to {{site.data.keyword.bpshort}} > Agents.
-
Select your Location to connect the Agent.
-
Click Connect Agent.
-
In the Connect an Agent to {{site.data.keyword.bpshort}} page, enter the input value.
- Agent name - Enter the unique name. For example,
myagent-connection
. - IAM Trusted ID - Link your trusted profile ID. For more information, to view the trusted profile ID, see Trusted Profile ID. For example,
Profile-1bd5eala-000-4a6666-00011
. - Resource Group - Select your resource group and specific resources where you need to connect a Agent. Check you have the right permissions for the resource group.
- Agent name - Enter the unique name. For example,
-
Click Connect.
- The Agent status will change to Ready to bind status. The Ready to bind status signifies that the Agent is ready for the next step to bind the workspace. Wait 15-30 minutes to view the Agent status. {: note}
-
Optional: From your Agent instance you can click the
...
dots to perform the following operations.- Edit Agent to edit the Agent configuration.
- Bind Agent to the {{site.data.keyword.bpshort}} Workspaces.
- Pause Agent to pause the Agent execution.
- Delete Agent to delete an Agent.
{: #register-api} {: api}
- Follow the steps to retrieve your IAM access token and authenticate with {{site.data.keyword.bplong_notm}} by using the API.
- You have the right permission to create
- VPC infrastructure.
- IKS cluster.
- LogDNA.
- Activity tracker services.
Here are the list of CURL commands use to register and unregister the Agent. For more information about the Agents related APIs
, see Agents APIs
.
-
Run post API to register an Agent with the {{site.data.keyword.bpshort}}.
curl -X POST \ https://schematics.cloud.ibm.com/v2/settings/agents \ -H 'authorization: ' \ -H 'cache-control: no-cache' \ -H 'content-type: application/json' \ -H 'github-token: github_token' \ -d '{ "name": "devclitestpart", "description": "Register agent", "resource_group": "Default", "tags": [ "agent" ], "location": "<Enter your location>", "agent_location": "<Enter your agent location>", "profile_id": "<Enter you profile_id>", "user_state": { "state": "enable" } }'
{: pre}
-
Run get all API to fetch all the registered or unregistered Agents from the Account.
curl -X GET \ https://schematics.cloud.ibm.com/v2/settings/agents \ -H 'authorization: ' \ -H 'cache-control: no-cache' \ -H 'content-type: application/json' \ -H 'github-token: github_token' \
{: pre}
-
Run get API to fetch a registered Agent details by providing the Agent ID in the path parameter.
curl -X GET \ https://schematics.cloud.ibm.com/v2/settings/agents/{agent_id} \ -H 'authorization: ' \ -H 'cache-control: no-cache' \ -H 'content-type: application/json' \ -H 'github-token: github_token' \
{: pre}
-
Optional: Update the Agent registration by providing the Agent ID in path parameter.
curl -X PUT \ https://schematics.cloud.ibm.com/v2/settings/agents/{agent_id} \ -H 'authorization: \ -H 'cache-control: no-cache' \ -H 'content-type: application/json' \ -d '{ "name": "devclitestpart", "description": "Register agent description changet", "resource_group": "string", "tags": [ "string" ], "location": "us-south", "agent_location": "us-south", "profile_id": "string", "user_state": { "state": "enable" } }'
{: pre}
-
Optional:
Deregister the Agent
by providing the Agent ID in path parameter.curl -X DELETE \ https://schematics.cloud.ibm.com/v2/settings/agents/{agent_id} \ -H 'authorization: ' \ -H 'cache-control: no-cache' \ -H 'content-type: application/json' \ -d ''
{: pre}
{: #connect-nextsteps}
You have completed the Agent connection to your {{site.data.keyword.bpshort}} service instance.
- Now, you need to Use an Agent to bind the Agent to your workspace.
- For any challenges in Agents installation or configuration, see FAQ about Agent and Troubleshooting guide.