Skip to main content
A secret is a named value, such as HF_TOKEN or WANDB_API_KEY, that every instance and job launched in an environment gets as an environment variable. Set your tokens once, and every machine has them, without the values ever going into a command, a launch script or your agent’s context.

What they are

  • Named per environment. A secret applies to one or more environments of the workspace. Machines launched in production get the secrets that apply to production, and nothing that applies only to staging. One name has at most one value in an environment.
  • Set in the dashboard. A workspace Owner or Manager adds, changes and removes secrets in Settings > Secrets (open it). You can type them one by one, or paste or drop a .env file. Everyone in the workspace can see which names exist.
  • Read, by name only, everywhere else. The API, the MCP server, the CLI and the SDKs list the names of an environment’s secrets, never their values, and none of them can set one.

How launches get them

When a machine starts, it fetches its variables from Runcrate and every shell on it has them: SSH sessions, the web terminal, the code editor, and a job’s command (also inside the job’s container image). A command reads them like any other variable:
A machine gets its variables in this order, a later one winning over an earlier one of the same name:
  1. The environment’s secret manager, when one is linked: Doppler, Infisical or 1Password, read at that moment.
  2. The environment’s secrets.
  3. Values set for this launch: the variables in the launch sheet, env_vars on POST /api/v1/instances, env on a job (runcrate run --env KEY=value, variables in the MCP run_job tool), or env / env_vars in a schedule’s spec.
  4. Runcrate’s own variables, such as RUNCRATE_ENVIRONMENT, RUNCRATE_INSTANCE_ID and, for jobs, RUNCRATE_JOB_ID. Names starting with RUNCRATE_ are reserved, so a secret can never replace them.
So a one-off value passed with a launch (--env HF_TOKEN=hf_other) overrides the environment’s HF_TOKEN for that launch only. Changes apply to the next launch. A machine that is already running keeps the values it started with, so relaunch it to pick up a changed secret. A job whose machine cannot fetch its variables does not run its command and fails, rather than running without them. Reruns and retries get the environment’s secrets as they are at that launch.

Limits

Sensitive secrets

Mark a secret Sensitive when nobody should ever read it back, such as a production database password. Its value is then hidden in Runcrate for everyone, including Owners, from then on. Every machine launched in its environments still gets it. A secret that is not sensitive can be revealed in the dashboard by an Owner or Manager, and every reveal is written to the audit log. Sensitive cannot be turned off again: to change that, delete the secret and add it again.

Secret managers

If your team already keeps its secrets in Doppler, Infisical or 1Password, connect it instead of copying values into Runcrate. Every launch and every job start in a linked environment reads it at that moment, so a value you rotate there reaches the next machine without a change in Runcrate. Runcrate stores the credential you give it, encrypted, and never stores a value it reads: only the names, so you can see where each variable comes from. It takes two steps, both for an Owner or Manager:
  1. Connect it once, in Settings > Integrations. Each manager has its own sheet that shows exactly how to make the credential, with links into the manager’s own pages and the one command that makes it. What you paste is checked as you type, then read once: you see who it is and what it can read before anything is saved, and a credential that can’t be read is never saved.
  2. Link it to an environment, in Settings > Secrets. Pick the connection, then its project and config, environment and path, or vault, from lists read live from the manager. You see the names that will come in, and which of them the environment’s own secrets already set, before you link. Each environment reads at most one.
Where the environment’s own secrets set the same name as its manager, the environment’s secret wins, and both rows on the Secrets page say so. A manager’s values count as Sensitive. While an environment reads a secret manager, its launches never go to a community host or a machine whose host can read its files and memory, exactly as with a Sensitive secret: such a launch is refused with sensitive_secrets_on_community_host or sensitive_secrets_on_host_readable_machine, and such a machine’s boot fetch gets nothing. Health. Each connection and each linked environment shows when it was last read and how that went: connected, access lost (a revoked or expired credential), not found (a renamed config or a removed vault), rate limited, not answering, or values refused, with what to do. Runcrate checks every one about every 30 minutes, by name only where the manager allows it, as well as at each launch, so a revoked token shows before a launch needs it. Check now reads it again. When a manager can’t be read, nothing starts without its values. A launch whose environment’s manager can’t be read is refused with Secret manager unreachable, the reason and where to fix it, before anything is created or billed: the launch sheet says so and links to Integrations, the API answers 502 with the code launch_refused, a job fails with that message, and a scheduled launch is recorded as failed. A machine also reads the manager again when it fetches its variables at boot; if the manager fails in that moment, the machine retries for two minutes, and a job’s command does not run without its variables. Rate limits. Each launch reads the manager two or three times (when it is requested, when the machine is created, and when the machine fetches its variables at boot), on top of the health check every 30 minutes. A large fan-out of jobs in one environment can therefore reach your manager’s own rate limits (1Password’s service accounts have hourly limits per token and daily limits per account). A read refused for that fails the launch like any other unreadable read, so check your plan’s limits before starting hundreds of jobs at once. A manager whose variables break the rules above is refused the same way, never partly used: a name starting with RUNCRATE_, a value over 32 KB or with a NUL character, more than 200 variables, or two 1Password items with the same title. Names that can’t be environment variables (my-key, 2FA_CODE) are skipped and listed when you link.

From the MCP server, CLI and SDKs

All of them show the secrets of the environment they act in: the one your agent connected to, the one runcrate envs switch picked, or the one your API key belongs to.
Ask your agent “which secrets does this environment have?”. The list_secrets tool returns each name, whether it is sensitive, when it last changed, and where it comes from (runcrate, or the environment’s secret manager such as doppler:backend/prd), with the reason when that manager is failing. When a job needs a token that is not there, the agent asks you to add it in the dashboard, or to connect your secret manager, instead of asking you to paste it into the chat.

How they are kept safe

  • Encrypted at rest. Each value is encrypted (AES-256-GCM) with a key kept outside the database, and each ciphertext only decrypts as the secret it was written for. The values you set for one launch, and a secret manager’s credential, are stored the same way. A secret manager’s values are never stored at all.
  • Never shown back. No API, MCP tool, CLI command or SDK returns a value. Lists, schedules and jobs show names only (env_keys). In the dashboard only a non-sensitive secret can be revealed, by an Owner or Manager, and the reveal is recorded.
  • Not in launch scripts. Values never travel in a machine’s startup script or its stored settings. Each machine fetches its own variables once, at boot, with a credential that only works for that machine and only for a short time after it starts.
  • Out of agents’ hands. An agent connected over MCP, or the CLI signed in with runcrate login, can list names but can never add, change or reveal a secret, or connect or link a secret manager, even when the person who connected it is an Owner. API keys can’t either.
  • Audited. Adding, changing, removing and revealing a secret, and connecting, disconnecting, linking and unlinking a secret manager, is recorded in the audit log with who and when, never with a value or a credential.
A job’s command, its logs, and a schedule’s launch_script and startup_commands are visible to everyone in the workspace. Keep tokens and passwords in secrets, or in launch values, never in the command itself. Anything your own program prints to the job log is visible too.