mirror of
https://github.com/coder/coder.git
synced 2026-09-24 15:04:27 +08:00
feat: make service accounts a Premium feature (#24020)
This commit is contained in:
@@ -1,31 +1,38 @@
|
||||
# Headless Authentication
|
||||
|
||||
Headless user accounts that cannot use the web UI to log in to Coder. This is
|
||||
useful for creating accounts for automated systems, such as CI/CD pipelines or
|
||||
for users who only consume Coder via another client/API.
|
||||
> [!NOTE]
|
||||
> Creating service accounts requires a [Premium license](https://coder.com/pricing).
|
||||
|
||||
You must have the User Admin role or above to create headless users.
|
||||
Service accounts are headless user accounts that cannot use the web UI to log in
|
||||
to Coder. This is useful for creating accounts for automated systems, such as
|
||||
CI/CD pipelines or for users who only consume Coder via another client/API. Service accounts do not have passwords or associated email addresses.
|
||||
|
||||
## Create a headless user
|
||||
You must have the User Admin role or above to create service accounts.
|
||||
|
||||
## Create a service account
|
||||
|
||||
<div class="tabs">
|
||||
|
||||
## CLI
|
||||
|
||||
Use the `--service-account` flag to create a dedicated service account:
|
||||
|
||||
```sh
|
||||
coder users create \
|
||||
--email="coder-bot@coder.com" \
|
||||
--username="coder-bot" \
|
||||
--login-type="none" \
|
||||
--service-account
|
||||
```
|
||||
|
||||
## UI
|
||||
|
||||
Navigate to the `Users` > `Create user` in the topbar
|
||||
Navigate to **Deployment** > **Users** > **Create user**, then select
|
||||
**Service account** as the login type.
|
||||
|
||||

|
||||
|
||||
</div>
|
||||
|
||||
## Authenticate as a service account
|
||||
|
||||
To make API or CLI requests on behalf of the headless user, learn how to
|
||||
[generate API tokens on behalf of a user](./sessions-tokens.md#generate-a-long-lived-api-token-on-behalf-of-another-user).
|
||||
|
||||
+2
-1
@@ -495,7 +495,8 @@
|
||||
{
|
||||
"title": "Headless Authentication",
|
||||
"description": "Create and manage headless service accounts for automated systems and API integrations",
|
||||
"path": "./admin/users/headless-auth.md"
|
||||
"path": "./admin/users/headless-auth.md",
|
||||
"state": ["premium"]
|
||||
},
|
||||
{
|
||||
"title": "Groups \u0026 Roles",
|
||||
|
||||
Reference in New Issue
Block a user