# Government installations

> Install the government build, sign in with your own Microsoft Entra ID, add your team, and keep updates under your control.

## What is different

The government build is the same `drkm` command and console, published to its own release feed. A machine installed from it updates from that feed only.

- **Install address.** `https://gov.drkm.com/install`, not `drkm.com`.
- **Models.** The model library offers models from US and French developers only. That limit covers the library. It does not cover a cloud provider you connect: pick a provider and model your authorization allows.
- **Console.** The console's horizon is black and white, so a government isotope is easy to tell apart.
- **No desktop or Android app.** Use the console in a browser and the `drkm` command.

## Before you install

You need three different kinds of access. Each one is granted separately.

| Access | What it lets you do | Who grants it |
| --- | --- | --- |
| **Installer access** | Download and update the government build | Darkmatter, in your agency's organization in its sign-in service |
| **Console account** | Sign in to an isotope | An administrator of that isotope |
| **Mesh membership** | Let isotopes run each other's work | An administrator of the mesh authority |

To get installer access, send Darkmatter the email address of each person who will install or update `drkm`. Darkmatter sets up an organization for your agency and gives those people installer access in it. Your identity administrator can connect your agency's Microsoft Entra ID to that organization, so your people sign in with their own accounts and multifactor authentication, and anyone your directory removes can no longer sign in. Until then, people sign in with a link sent to their email. Installer access lets someone install and update `drkm` and nothing else; it gives no access to your isotopes, which sign people in on their own.

Plan the hardware:

- **An isotope other people or machines connect to runs on Linux.** A Mac isotope is reachable only from that Mac, so use a Mac for a single-operator isotope.
- **Give a Linux isotope at least 16 GiB of memory and 6 CPUs.** 8 GiB runs out of memory under heavy work.
- Run the installer as your own user, not root, on Apple silicon macOS or on x86-64 or ARM64 Linux.

## Install

Run the government installer. It prints a sign-in link and an eight-character code. Open the link on any device, sign in with the account that has installer access, and confirm the code. The code expires after five minutes. Everything else matches [installation](https://docs.drkm.com/installation).

```bash Terminal
curl -fsSL https://gov.drkm.com/install | sh

~/.local/bin/drkm --version
```

If the installer stops partway, run the same command again.

## Choose how people sign in

The first `drkm start` asks how the isotope signs people in. Choose before you start:

- **Log in with Darkmatter** to sign people in with their Darkmatter accounts, or your agency's Microsoft Entra ID once it is connected to Darkmatter login; see [Use Microsoft Entra ID](https://docs.drkm.com/iam#use-microsoft-entra-id). People use their existing accounts and MFA, and someone removed from your directory can no longer sign in. Nothing is registered for the isotope.
- **Local accounts** for a disconnected isotope. You create the administrator with your email and a password, then add each person in **Settings → Users** and hand them a temporary password.

Setup never changes the method once it is saved.

## Add your team

In **Settings → Users**, an administrator adds people:

- **With the built-in administrator**, **Settings → Users → Invite user** takes an email and a role. For someone new it shows a temporary password once; hand it over yourself, since no email is sent, and they choose their own password at first sign-in. Someone who already has a login here just gets the access, with no new password.
- **With Entra**, either **Invite user** by the email Entra holds for them, or set **Access → Who can sign in** to _Anyone in the identity provider_ with a default role. To decide who that is in Entra, turn on **Assignment required** for the isotope's enterprise application and assign a group.

Roles are described in [identity and access](https://docs.drkm.com/iam#roles). To connect more isotopes, see [add devices to the mesh](https://docs.drkm.com/mesh).

## Keep updates under your control

Installation registers an update key for the machine. That key belongs to the account that approved the installation, and it keeps working without anyone signing in again. Have one of your own people approve each installation. If someone else installed a machine, hand the updates over:

```bash Terminal
# On the machine, signed in as the new owner
drkm update --authorize

# As the previous owner: list your machines and revoke the old key
drkm update --list-machines
drkm update --revoke <machine-id>
```

Removing a person's installer access does not stop machines they approved from updating, and revoking needs that access. Revoke their machines' keys first. Isotopes update themselves once a day unless an administrator turns **Automatic updates** off in **Settings → Updates**.

## When someone leaves

1. Block them in **Settings → Users**. Blocking ends their access at once and keeps their conversations. Removing them from Entra stops new sign-ins, but a console session lasts up to 12 hours.
2. On each machine they approved that you keep using, someone on your team runs `drkm update --authorize`, so it updates under their own account.
3. Ask Darkmatter to close their installer account. Darkmatter revokes the update keys it still holds first, even if they have already left.
