-
Notifications
You must be signed in to change notification settings - Fork 31
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
143 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
External configurations are for setting up | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
|
||
<details className="config-field" data-expandable="false" open> | ||
<summary> | ||
|
||
## `external` <span className="config-field-required" data-required="false">required</span> <span className="config-field-type">object</span> <span className="config-field-default"></span> <span className="config-field-enum"></span> <span data-pro="false" className="config-field-pro">pro</span> {#external} | ||
|
||
External holds configuration for tools that are external to the vCluster. | ||
|
||
</summary> | ||
|
||
|
||
|
||
</details> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,48 @@ | ||
|
||
<details className="config-field" data-expandable="true"> | ||
<summary> | ||
|
||
## `apiKey` <span className="config-field-required" data-required="false">required</span> <span className="config-field-type">object</span> <span className="config-field-default"></span> <span className="config-field-enum"></span> <span data-pro="false" className="config-field-pro">pro</span> {#apiKey} | ||
|
||
APIKey defines where to find the platform access key and host. By default, vCluster will search in the following locations in this precedence: | ||
* platform.api.accessKey | ||
* environment variable called LICENSE | ||
* secret specified under external.platform.apiKey.secretName | ||
* secret called "vcluster-platform-api-key" in the vCluster namespace | ||
|
||
</summary> | ||
|
||
|
||
|
||
|
||
<details className="config-field" data-expandable="false" open> | ||
<summary> | ||
|
||
### `secretName` <span className="config-field-required" data-required="false">required</span> <span className="config-field-type">string</span> <span className="config-field-default"></span> <span className="config-field-enum"></span> <span data-pro="false" className="config-field-pro">pro</span> {#apiKey-secretName} | ||
|
||
SecretName is the name of the secret where the platform access key is stored. This defaults to vcluster-platform-api-key if undefined. | ||
|
||
</summary> | ||
|
||
|
||
|
||
</details> | ||
|
||
|
||
|
||
<details className="config-field" data-expandable="false" open> | ||
<summary> | ||
|
||
### `namespace` <span className="config-field-required" data-required="false">required</span> <span className="config-field-type">string</span> <span className="config-field-default"></span> <span className="config-field-enum"></span> <span data-pro="false" className="config-field-pro">pro</span> {#apiKey-namespace} | ||
|
||
Namespace defines the namespace where the access key secret should be retrieved from. If this is not equal to the namespace | ||
where the vCluster instance is deployed, you need to make sure vCluster has access to this other namespace. | ||
|
||
</summary> | ||
|
||
|
||
|
||
</details> | ||
|
||
|
||
</details> |
59 changes: 59 additions & 0 deletions
59
vcluster/configure/vcluster-yaml/external/platform/api-key.mdx
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,59 @@ | ||
--- | ||
title: apiKey | ||
sidebar_label: apiKey | ||
--- | ||
|
||
import ApiKey from '@site/vcluster/_partials/config/external/platform/apiKey.mdx' | ||
import External from '@site/vcluster/_partials/config/external.mdx' | ||
|
||
<External /> | ||
|
||
## Config reference | ||
|
||
<ApiKey /> | ||
|
||
## Permissions | ||
You need to add the `spec.scope.roles[*].role=vcluster` in the Platform Access Key OwnedAccessKey CRD. The UI does not support this other than allowing you to enter freeform in the CRD editor. | ||
|
||
```yaml | ||
spec: | ||
scope: | ||
roles: | ||
- role: "vcluster" | ||
``` | ||
## Secret | ||
:::note | ||
`external.platform.apiKey.value` is no longer supported. It has to be in a secret, specified in the `external.platform.apiKey.secretName` field. | ||
::: | ||
|
||
Store the platform connection details in a secret on the host cluster. | ||
|
||
```yaml | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
name: vcluster-platform-api-key | ||
namespace: my-namespace | ||
type: Opaque | ||
data: | ||
access-key: <base64-encoded-access-key> | ||
host: <base64-encoded-host> | ||
project: <base64-encoded-project-name> | ||
apiVersion: v1 | ||
kind: Secret | ||
metadata: | ||
name: vcluster-platform-api-key | ||
namespace: default | ||
stringData: | ||
accessKey: <access-key> | ||
host: <host> | ||
``` | ||
|
||
## Projects | ||
|
||
Set the project key in the platform apiKey secret to allows you to specify the project where the vCluster should be imported into. If undefined, it goes into `default`. | ||
|
||
|