Skip to main content

Setup

This page covers one-time machine setup for the ymirr CLI v2: environment variables and global npm packages.

Environment variables​

Deployments and Netrunner need several secrets and config values. The CLI can write them into ~/.ymirr-env and optionally add a line to your shell profile so they are loaded in every terminal.

Configure via CLI​

ymirr setup

Choose Environment variables (or Everything). You can:

  • Fill only missing values, reconfigure all, or pick specific variables.
  • For KUBE_CONFIG, choose “Read from ~/.kube/config” to base64-encode it automatically.

The file is saved as ~/.ymirr-env. If the CLI added a line to ~/.bashrc, new shells will load it. In the current shell, run:

source ~/.ymirr-env

Variables reference​

VariablePurpose
PULUMI_ORGPulumi organization (e.g. IVFuture)
PULUMI_ACCESS_TOKENPulumi Cloud access token
CLOUDFLARE_API_TOKENCloudflare API token
VAULT_ADDRHashiCorp Vault URL (e.g. https://vault.semiotic.eu)
VAULT_TOKENVault auth token
KUBE_CONFIGBase64-encoded kubeconfig
CLI_AUTH_TOKENNetrunner / auth token
API_URLNetrunner API base (e.g. https://netrunner.semiotic.eu/)

The CLI loads ~/.ymirr-env at startup when the file exists, so deployments and Netrunner see these values.

Global packages​

For deploy and netrunner to work, the following are needed:

  • @ymirr/pulumi-infra — Used when running Pulumi (deploy/destroy). The CLI looks for it in the global npm root or the current project’s node_modules.
  • @ymirr/netrunner — Used for ymirr netrunner clone .... Must be installed globally (or the CLI will prompt you).

Install via CLI​

ymirr setup

Choose Global packages (or Everything). The CLI checks that the @ymirr registry is configured in ~/.npmrc and runs:

npm install -g @ymirr/pulumi-infra
npm install -g @ymirr/netrunner

Registry config​

Ensure your npm registry is set for the @ymirr scope (and auth if the registry is private). Example ~/.npmrc:

@ymirr:registry=https://npm.ivfuture.uk/
//npm.ivfuture.uk/:_authToken=<your-token>

If you use a different registry URL or auth method, configure it before running ymirr setup → Global packages.

Summary​

  1. Run ymirr setup.
  2. Configure Environment variables (writes ~/.ymirr-env; optionally sources it from ~/.bashrc).
  3. Install Global packages (requires @ymirr registry in ~/.npmrc).
  4. In a new terminal (or after source ~/.ymirr-env), use ymirr deploy and ymirr netrunner as needed.