> ## Documentation Index
> Fetch the complete documentation index at: https://docs.macstadium.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Understanding Orka Credentials

> Learn how Orka's three credential systems work, when to use each, and how to avoid the common mistake of using short-lived tokens in CI/CD pipelines.

New Orka users typically hit three different credential prompts before they can do anything useful, and none of the three are the same thing. Here's how they fit together. For how they connect to roles and namespaces, see [How access works in Orka](https://docs.macstadium.com/orka/orka-cluster-access/how-access-works.md).

## The three systems

### 1. MacStadium portal credentials

Your MacStadium account username and password. Use these to log in to [portal.macstadium.com](https://portal.macstadium.com) to access My Cloud, manage billing, and request changes to your cluster.

You also use them to sign in to Orka: `orka login` and the Orka web UI ask for them. On their own they don't run commands. `orka login` exchanges them for a short-lived Orka token.

### 2. Orka user tokens

The token the Orka CLI uses for your requests. You get one by signing in with your portal credentials:

```bash theme={null}
orka login
```

This mints a **short-lived token that expires after 1 hour.** The token carries your identity and Portal role. Which namespaces you can work in depends on role bindings, not on the token.

> [!WARNING]
>
> Do not use `orka login` or `orka user get-token` in CI/CD pipelines. Tokens expire after 1 hour and will break long-running jobs.

**For CI/CD, use service accounts instead:**

```bash theme={null}
orka sa create <SERVICE_ACCOUNT_NAME>
orka sa token <SERVICE_ACCOUNT_NAME> --no-expiration
```

Service account tokens are long-lived (default: 1 year) or non-expiring, and are designed to be injected as environment variables in your pipeline. See [Manage Service Accounts](https://docs.macstadium.com/orka/orka-cluster-access/orka-cluster-manage-service-accounts.md) for the full workflow.

### 3. VM credentials

The macOS username and password inside each VM. These are what you use to SSH in or connect via Screen Sharing.

MacStadium base images ship with default credentials:

* **Username:** `admin`
* **Password:** `admin`

> [!WARNING]
>
> Change the default VM password after your first login. The default `admin/admin` credentials are well known and your VMs are accessible to anyone with VPN access to your cluster.

## Quick reference

| Credential | Used for | Expires |
| - | - | - |
| MacStadium portal login | portal.macstadium.com (billing, My Cloud, account), `orka login`, and the Orka web UI | No |
| `orka login` token | CLI and web UI (human use) | 1 hour |
| Service account token | CI/CD pipelines and automation | 1 year (or never) |
| VM credentials | SSH, VNC into VMs | Never (until you change them) |

## Common mistakes

**Using `orka login` in a pipeline.** The token will expire mid-job and cause confusing authentication errors. Use a service account.

**Rotating portal credentials and expecting Orka to break.** They're independent: changing your portal password doesn't affect your Orka tokens or service accounts.

**Leaving VM credentials at `admin/admin`.** Every VM on your cluster shares the same default, so a single compromised VM credential means all of them are exposed.


## Related topics

- [How access works in Orka](https://docs.macstadium.com/orka/orka-cluster-access/how-access-works.md)
- [Manage macOS VM images with the Orka CLI](https://docs.macstadium.com/orka/orka-cli-reference/image-management.md)
- [Manage OCI registry credentials in Orka](https://docs.macstadium.com/orka/oci-images/oci-images-manage-registry-credentials.md)
- [Orka CLI OCI registry credential commands](https://docs.macstadium.com/orka/orka-cli-reference/oci-registry-integration.md)
- [Orka node management with the CLI](https://docs.macstadium.com/orka/orka-cli-reference/node-management.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.