From b5e09a26de6afb0c194613c6ee4d22a22a0fce14 Mon Sep 17 00:00:00 2001 From: Mayra Cabrera Date: Mon, 1 Apr 2019 16:29:05 +0000 Subject: Include cluster domain into Project Cluster API Domain was introduced on 11.8 and was not included on the Project Cluster API. With this change user will be able to include domain when adding and updating a cluster. Domain will also be included on the GET calls. Closes https://gitlab.com/gitlab-org/gitlab-ce/issues/59441 --- doc/api/project_clusters.md | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'doc') diff --git a/doc/api/project_clusters.md b/doc/api/project_clusters.md index 8efb98fe1fc..02334f0298e 100644 --- a/doc/api/project_clusters.md +++ b/doc/api/project_clusters.md @@ -33,6 +33,7 @@ Example response: { "id":18, "name":"cluster-1", + "domain":"example.com", "created_at":"2019-01-02T20:18:12.563Z", "provider_type":"user", "platform_type":"kubernetes", @@ -90,6 +91,7 @@ Example response: { "id":18, "name":"cluster-1", + "domain":"example.com", "created_at":"2019-01-02T20:18:12.563Z", "provider_type":"user", "platform_type":"kubernetes", @@ -157,6 +159,7 @@ Parameters: | --------- | ---- | -------- | ----------- | | `id` | integer | yes | The ID of the project owned by the authenticated user | | `name` | String | yes | The name of the cluster | +| `domain` | String | no | The [base domain](../user/project/clusters/index.md#base_domain) of the cluster | | `enabled` | Boolean | no | Determines if cluster is active or not, defaults to true | | `platform_kubernetes_attributes[api_url]` | String | yes | The URL to access the Kubernetes API | | `platform_kubernetes_attributes[token]` | String | yes | The token to authenticate against Kubernetes | @@ -247,6 +250,7 @@ Parameters: | `id` | integer | yes | The ID of the project owned by the authenticated user | | `cluster_id` | integer | yes | The ID of the cluster | | `name` | String | no | The name of the cluster | +| `domain` | String | no | The [base domain](../user/project/clusters/index.md#base_domain) of the cluster | | `platform_kubernetes_attributes[api_url]` | String | no | The URL to access the Kubernetes API | | `platform_kubernetes_attributes[token]` | String | no | The token to authenticate against Kubernetes | | `platform_kubernetes_attributes[ca_cert]` | String | no | TLS certificate (needed if API is using a self-signed TLS certificate | @@ -262,7 +266,7 @@ Example request: ```bash curl --header 'Private-Token: ' https://gitlab.example.com/api/v4/projects/26/clusters/24 \ -H "Content-Type:application/json" \ --X PUT --data '{"name":"new-cluster-name","api_url":"https://new-api-url.com"}' +-X PUT --data '{"name":"new-cluster-name","domain":"new-domain.com","api_url":"https://new-api-url.com"}' ``` Example response: @@ -271,6 +275,7 @@ Example response: { "id":24, "name":"new-cluster-name", + "domain":"new-domain.com", "created_at":"2019-01-03T21:53:40.610Z", "provider_type":"user", "platform_type":"kubernetes", -- cgit v1.2.1