You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/vendor/replicated-api-tokens.md
+16-29Lines changed: 16 additions & 29 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,18 +14,18 @@ Using the Replicated CLI and Vendor API V3 requires an API token for authorizati
14
14
15
15
The following types of tokens are available:
16
16
17
-
-[Service Accounts](#service-accounts)
18
-
-[User API Tokens](#user-api-tokens)
17
+
-[Service accounts](#service-accounts)
18
+
-[User API tokens](#user-api-tokens)
19
19
20
20
<TeamTokenNote/>
21
21
22
22
### Service accounts
23
23
24
-
Service accounts are assigned a token and associated with an RBAC policy. Users with the proper permissions can create, retrieve, or revoke service account tokens. Admin users can assign any RBAC policy to a service account. Non-admin users can only assign their own RBAC policy when they create a service account.
24
+
Service accounts are assigned a token and an RBAC policy. Users with the proper permissions can create, view, and revoke service accounts.
25
25
26
26
Service accounts are useful for operations that are not tied to a particular user, such as CI/CD or integrations.
27
27
28
-
Updates to a service account's RBAC policy are automatically applied to its associated token. When a service account is removed, its tokens are also invalidated.
28
+
When a service account is removed, its tokens are also invalidated.
29
29
30
30
### User API tokens
31
31
@@ -35,44 +35,31 @@ Updates to a user's RBAC role are applied to all of the tokens belonging to that
35
35
36
36
Revoking a user token immediately invalidates that token. When a user account is deleted, its user tokens are also deleted.
37
37
38
-
## Generate tokens
38
+
## Create a service account
39
39
40
-
To use the Replicated CLI or the Vendor API v3, you need a User API token or a Service Account token. Existing team API tokens also continue to work.
41
-
42
-
### Generate a service account
43
-
44
-
To generate a service account:
45
-
46
-
1. Log in to the Vendor Portal, and select [**Team > Service Accounts**](https://vendor.replicated.com/team/serviceaccounts).
47
-
1. Select **New Service Account**. If one or more service accounts already exist, you can add another by selecting **New Service Account**.
40
+
To create a service account:
48
41
42
+
1. In the Vendor Portal, go to [**Team > Service Accounts**](https://vendor.replicated.com/team/serviceaccounts).
43
+
1. Click **Create Service Account**.
49
44
1. Edit the fields in the **New Service Account** dialog:
50
45
51
-
<imgalt="New Service Accounts Dialog"src="/images/service-accounts.png"width="400px"/>
52
-
53
-
[View a larger version of this image](/images/service-accounts.png)
54
-
55
-
1. For **Nickname**, enter a name the token. Names for service accounts must be unique within a given team.
46
+
1. For **Nickname**, enter a name for the service account. Service account names must be unique within the team.
56
47
57
-
1. For **RBAC**, select the RBAC policy from the dropdown list. The token must have `Admin` access to create new releases.
48
+
1. For **RBAC**, select an RBAC policy to assign to the service account. For more information about how to create custom RBAC policies, see [Configure RBAC Policies](team-management-rbac-configuring).
58
49
59
-
This list includes the Vendor Portal default policies `Admin` and `Read Only`. Any custom policies also display in this list. For more information, see [Configure RBAC Policies](team-management-rbac-configuring).
50
+
Note the following:
51
+
* Admin users can assign any RBAC policy to a service account. Non-admin users can only assign an RBAC policy with their same level of access to avoid permission elevation.
52
+
* After you create a service account, you can't change which RBAC policy is assigned to the service account. If you need to change the RBAC for an existing service account that uses a custom RBAC policy, then you can update the custom RBAC policy itself. Updates to the RBAC policy are automatically applied to the service account's associated token. Or, you can create a new service account and assign it a different RBAC policy.
60
53
61
-
Users with a non-admin RBAC role cannot select any other RBAC role when creating a token. They are restricted to creating a token with their same level of access to avoid permission elevation.
54
+
1. (Optional) Select **Limit to read-only version of above policy** if you selected a custom RBAC policy that has Read/Write permissions but you want to limit this service account to read-only. This option lets you maintain one version of a custom RBAC policy and use it two ways: as read/write and as read-only.
62
55
63
-
1. (Optional) For custom RBAC policies, select the **Limit to read-only version of above policy** check box to if you want use a policy that has Read/Write permissions but limit this service account to read-only. This option lets you maintain one version of a custom RBAC policy and use it two ways: as read/write and as read-only.
64
-
65
-
1. Select **Create Service Account**.
56
+
1. Click **Create Service Account**.
66
57
67
58
1. Copy the service account token and save it in a secure location. The token will not be available to view again.
68
59
69
60
1. (Recommended) Add the token to a Replicated authentication profile. See [Authenticate](/reference/replicated-cli-installing#auth) in _Installing the Replicated CLI_.
70
61
71
-
:::note
72
-
To remove a service account, select **Remove** for the service account that you want to delete.
0 commit comments