Skip to content

Latest commit

 

History

History
70 lines (48 loc) · 1.42 KB

secret_create.md

File metadata and controls

70 lines (48 loc) · 1.42 KB
title secret create
description Create a secret
product Coder
section reference
source_url https://coder.com/docs/reference/cli/secret_create
fetched 2026-09-26
tags
coder
reference

Create a secret

Usage

coder secret create [flags] <name>

Description

Provide the secret value with --value or non-interactive stdin (pipe or redirect).

Options

--value

Type string

Set the secret value. For security reasons, prefer non-interactive stdin (pipe or redirect).

--description

Type string

Set the secret description.

--env

Type string

Name of the workspace environment variable that this secret will set.

--file

Type string

Workspace file path where this secret will be written. Must start with ~/ or /.

--enabled

Type bool
Default true

Whether the secret is injected into workspaces. An enabled secret must set --env or --file; pass --enabled=false to store a secret without injecting it.