Skip to content

Getting Started

Get up and running with skret in under 5 minutes.

The whole loop is two commands — the same shape as doppler setup && doppler run:

Terminal window
skret setup # pick provider + path, then authenticate (once)
skret run -- <command> # run anything with secrets injected

skret setup authenticates once (SSO refreshes silently for the whole session, or a stored access key) so you never re-run aws login. The sections below walk through each piece.

Terminal window
# macOS
brew install n24q02m/tap/skret
# Windows
scoop bucket add n24q02m https://github.com/n24q02m/scoop-bucket
scoop install skret
# Go
go install github.com/n24q02m/skret/cmd/skret@latest

Navigate to your project root and run:

Terminal window
skret init --provider=aws --path=/myapp/prod --region=us-east-1

This creates .skret.yaml and updates .gitignore.

Terminal window
# Set a secret
skret set DATABASE_URL "postgres://user:pass@host/db"
# Get it back
skret get DATABASE_URL
# List all secrets
skret list
# Run your app with secrets injected
skret run -- npm start

Edit .skret.yaml to add environments:

version: "1"
default_env: prod
environments:
prod:
provider: aws
path: /myapp/prod
region: us-east-1
dev:
provider: local
file: ./.secrets.dev.yaml

Switch environments:

Terminal window
skret --env=dev get DATABASE_URL
skret --env=prod list
Terminal window
# From .env file
skret import --from=dotenv --file=.env
# From Doppler
DOPPLER_TOKEN=dp.st.xxx skret import --from=doppler --doppler-project=myapp --doppler-config=prd
# From Infisical
INFISICAL_TOKEN=st.xxx skret import --from=infisical --infisical-project-id=... --infisical-env=prod