Creating Service Endpoints
Scenario
A service endpoint is an extension of CodeArts. It enables CodeArts to connect to third-party services.
For example, when your CodeArts tasks need to obtain project source code from a third-party GitHub repository or need to run with Jenkins, you can create an endpoint to connect to each service.
Type |
Scenario |
---|---|
Docker repository |
Connects to a Docker image repository to obtain images for CodeArts Deploy. |
Jenkins |
Connects to Jenkins to execute Jenkins tasks in pipelines. |
Kubernetes |
Connects to a Kubernetes cluster to deliver deployment tasks. |
nexus repository |
Connects to a third-party private Maven repository to obtain file information for build tasks. |
Git repository |
Connects to a third-party Git repository to obtain branch information for CodeArts Pipeline and CodeArts Build. |
GitHub |
Connects to a GitHub account to obtain its repository and branch information for CodeArts Pipeline and CodeArts Build. |
IAM user |
Delegates your AK/SK to an IAM user so that the user can obtain a token to perform tasks that require higher permissions. |
CodeArts Repo HTTPS |
Authorizes CodeArts to download code, create branches, merge branches, and commit code in CodeArts Repo repositories. Currently, it is used for change-triggered pipelines and related extensions. |
GitLab |
Connects to a GitLab repository to obtain branch information for CodeArts Pipeline and CodeArts Build. |
Prerequisites
- You have the endpoint edit permission for the target CodeArts project.
- The third-party service to connect can be accessed from the public network without restrictions.
Creating a Docker Repository Service Endpoint
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name to access the project.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose Docker repository from the drop-down list.
- Configure the following information and click Confirm.
Table 2 Creating a Docker repository service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
Repository Address
Yes
Address of the Docker repository to connect. HTTP and HTTPS addresses are supported.
Username
Yes
Username of the Docker repository to connect. Enter a maximum of 256 characters.
Password
Yes
Password of the Docker repository to connect. Enter a maximum of 256 characters.
- Check the new service endpoint.
Creating a Jenkins Service Endpoint
Currently, Jenkins service endpoints are not supported in LA-Santiago and TR-Istanbul.
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose Jenkins from the drop-down list.
- Configure the following information and click Confirm.
Table 3 Creating a Jenkins service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
Server URL
Yes
Address of the Jenkins service to connect. The address can be in format "http://ip:Port" or "https://ip:Port".
Username
Yes
Username of the Jenkins service to connect. Enter a maximum of 300 characters.
Password
Yes
Password of the Jenkins service to connect. Enter a maximum of 300 characters.
- Check the new service endpoint.
Creating a Kubernetes Service Endpoint
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose Kubernetes from the drop-down list.
- Configure the following information and click Verify and Confirm.
Table 4 Creating a Kubernetes service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
Kubernetes URL
Yes
Server address of the cluster to connect. Obtain it by searching for server in kubeconfig.json.
Kubeconfig
Yes
Content of the cluster's kubeconfig.json file.
- Check the new service endpoint.
Creating a Nexus Repository Service Endpoint
Currently, Nexus repository service endpoints are not supported in LA-Santiago and TR-Istanbul.
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose nexus repository from the drop-down list.
- Configure the following information and click Confirm.
Table 5 Creating a Nexus repository service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
Repository Address
Yes
Address of the Nexus repository to connect. HTTP and HTTPS addresses are supported.
Username
Yes
Username of the Nexus repository to connect. Enter a maximum of 300 characters.
Password
Yes
Password of the Nexus repository to connect. Enter a maximum of 300 characters.
- Check the new service endpoint.
Creating a Git Service Endpoint
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose Git repository from the drop-down list.
- Configure the following information and click Confirm.
Table 6 Creating a Git service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
Git Repository URL
Yes
HTTPS address of the Git repository to connect.
Username
No
Username of the Git repository to connect. Enter a maximum of 300 characters.
Password or Access Token
No
Password of the Git repository to connect. Enter a maximum of 300 characters.
- Check the new service endpoint.
Creating a GitHub Service Endpoint
Currently, GitHub service endpoints are not supported in LA-Santiago.
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose GitHub from the drop-down list.
- Configure the following information and click Authorize and Confirm.
Table 7 Creating a GitHub service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
Authentication Mode
Yes
Two authentication modes are supported:
- OAuth: After clicking Authorize and Confirm, log in to GitHub for manual authorization.
- Access token: Enter your access token obtained in GitHub. For details, see GitHub official website.
- Check the new service endpoint.
Creating an IAM User Service Endpoint
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose IAM user from the drop-down list.
- Configure the following information and click Confirm.
Table 8 Creating an IAM user service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
Access Key Id
Yes
AK obtained on the My Credentials page. For details, see Access Keys.
Secret Access Key
Yes
SK obtained on the My Credentials page. For details, see Access Keys.
- Check the new service endpoint.
Creating a CodeArts Repo HTTPS Service Endpoint
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose CodeArts Repo HTTPS from the drop-down list.
- Configure the following information and click Confirm.
Table 9 Creating a CodeArts Repo HTTPS service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
CodeArts Repo URL
Yes
HTTPS address of the CodeArts Repo repository to connect.
Go to the target repository, and click Clone/Download. Click Clone with HTTPS, and obtain the repository address.
Username
No
HTTPS username of the CodeArts Repo repository to connect.
Click the username on the navigation bar and choose This Account Settings. Obtain the username on the Repo > HTTPS Password page.
Password
No
HTTPS password of the CodeArts Repo repository to connect.
Click the username on the navigation bar and choose This Account Settings. Obtain the password on the Repo > HTTPS Password page.
- Check the new service endpoint.
Creating a GitLab Repository Service Endpoint
- Go to the CodeArts homepage.
- Log in to the CodeArts console, click , and select a region.
- Click Access Service.
- On the CodeArts homepage, click a project name.
- In the navigation pane, choose Settings > General > Service Endpoints.
- Click Create Endpoint and choose GitLab repository from the drop-down list.
- Configure the following information and click Confirm.
Table 10 Creating a GitLab repository service endpoint Parameter
Mandatory
Description
Service Endpoint Name
Yes
Enter a maximum of 256 characters, including letters, digits, hyphens (-), underscores (_), periods (.), and spaces.
GitLab URL
Yes
HTTPS address of the GitLab repository to connect.
Username
No
Username of the GitLab repository to connect.
Access Token
No
Access token for the GitLab repository to connect. For details, see GitLab official website.
- Check the new service endpoint.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot