Skip to main content

r/dotfiles


​[BSPWM] Minimal & Fast Arch Linux Workflow
[deleted]
​[BSPWM] Minimal & Fast Arch Linux Workflow
Image r/dotfiles - ​[BSPWM] Minimal & Fast Arch Linux Workflow

Advertisement: Sound on. Lights off. Discover survival games on Roblox.
Sound on. Lights off. Discover survival games on Roblox.
media poster


[dwm] My daily driver Linux desktopr
[dwm] My daily driver Linux desktopr
Image r/dotfiles - [dwm] My daily driver Linux desktopr

Storing age-encrypted secrets in a public dotfiles repo — how risky is it?
Storing age-encrypted secrets in a public dotfiles repo — how risky is it?

My dotfiles repo is currently private, but I'm considering making it public. One thing holding me back is that I store encrypted secrets in it, and I'm curious how others handle this.

Here's my current setup:

  • I use GNU Stow to manage dotfiles across multiple machines (MacBook, Mac Mini, etc.).

  • I wrote a small CLI utility called dotsecrets that uses age to encrypt secrets and store them as .age files in a directory within my dotfiles repo.

  • My age identities/private keys live outside the repo in a known location on each machine.

  • When I add a secret (API tokens, personal information, etc.), dotsecrets encrypts it and commits the encrypted file to the repo.

  • On another machine, I pull the repo and run dotsecrets to decrypt those files into a local directory outside the repo, where my scripts and CLI tools can access them.

For example, I built a small CLI tool that acts as a shared scratchpad between my computers using a remote API. Both machines need the same API token, so I distribute it through my encrypted dotfiles.

I also encrypt things that aren't technically secrets but that I'd rather not expose publicly, like my home address.

None of the secrets I'm storing would be catastrophic if compromised. Mostly API tokens and personal information that would be a moderate inconvenience to rotate or clean up.

My questions:

  1. How do you manage and synchronize secrets across machines alongside your dotfiles? Is there a better approach I should consider?

  2. How risky is it to publish a dotfiles repo containing age-encrypted secrets? My understanding is that age uses strong, modern encryption, so assuming my private keys remain secure, the actual risk of someone decrypting those files is extremely low. Am I overlooking anything?

I'd love to hear how others approach this, especially those maintaining public dotfiles repos.