Skip to content
Public template

About

Example team data for rekey — use this template to start your own (private)

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Latest commit

 

History

3 Commits

Folders and files

Repository files navigation

English · 한국어 · 中文 · 日本語 · Español

rekey example

Example team data for rekey: where each API key of a made-up company, Acme, is used. Keys live in three vaults, Acme - Prod, Acme - Dev and Acme - Local, and are named <project>.<service>. Every value is fake, and there are no key values at all: those live in 1Password.

Start your own

  1. Use this template (button above) → create a private repository. Team data shows how your infrastructure is wired, so keep it private.
  2. Get the tool and your copy:
    pipx install git+https://github.com/golbin/rekey
    git clone <your new repo> ~/code/keys      # next to your projects
    cd ~/code/keys
  3. Replace the examples with your own:
    rm -r targets keys.toml
    rekey init --vault "<your vault>" --source vercel --source supabase --source railway
    rekey arrange "<your vault prefix> - {env}"   # one vault per environment
    rekey import all
    git add . && git commit -m "Our keys"

Then follow the setup guide.

Look around first

No 1Password needed for this:

rekey ls                                    # 14 keys in 3 vaults, how each is issued, where it is used
rekey where shop.openai                     # the same name in Prod, Dev and Local: one key per environment
REKEY_STORE=file:/tmp/rekey.json rekey rotate all --dry-run   # what a rotation would do
File Shows
targets/shop/file/shop/web/.env.local.tpl a local .env: keys only, a password inside a URL
targets/shop/file/shop/api/.env.tpl an R2 key pair (two fields of one key)
targets/shop/vercel/shop/production.tpl plain settings next to keys, and a variable rekey can't read
targets/shop/vercel/shop/preview.tpl the same key in another environment
targets/api/railway/shop/production/api.tpl a Railway service
targets/shop/supabase/<ref>.tpl Supabase Edge Function secrets
targets/shop/github/acme/shop/production.tpl a GitHub Actions secret in an environment
targets/old-blog/file/old-blog/.env.tpl a key only a retired project still has
keys.toml locked, check, retire, note, page

About

Example team data for rekey — use this template to start your own (private)

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages