Skip to content

Instantly share code, notes, and snippets.

@mrlaessig
mrlaessig / secure_envrc_files.md
Created February 4, 2026 14:40
Secure .envrc files with sops and direnv

Secure .envrc files

A common use case is sourcing local environment variables, for example with direnv, and storing them in a .envrc file. To prevent accidentally committing secrets to a repository and pushing them to origin, it’s best to encrypt local secrets. Although direnv does not support this by default, you can integrate it nicely with sops, GnuPG, and a helper function.

Install dependencies

We need direnv and sops to encrypt files, and GnuPG to create encryption keys.

# On macOS this can be installed with Homebrew.
# On any other OS, use your package manager.
$ brew install direnv sops gnupg
@mrlaessig
mrlaessig / arch-linux-install.md
Last active February 4, 2026 14:47 — forked from binaerbaum/arch-linux-install
Minimal instructions for installing arch linux on an UEFI NVMe system with full system encryption using dm-crypt and luks

Installing Arch Linux with Full-Disk Encryption and UEFI (LUKS + LVM)

This guide turns the official installation steps into a practical, copy‑pasteable walkthrough for a UEFI system with an encrypted root volume using LUKS and LVM. It assumes you are comfortable working in a live environment and want a clean, minimal Arch install with swap and root on encrypted storage.

If you want a more exhaustive reference, consult the Arch Installation Guide (official wiki).


1) Prepare installation media