e96f291048d83181be5669e3977129b798efd7d5
HakaseOS
HakaseOS is an opinionated NixOS configuration heavily inspired by OmarchyOS.
Features
- Vim keybindings
- Simple Setup
- Pre-configured Firefox
To-do
- TUI for everything
How to Use SOPS
SOPS is an important aspect of this operating system. Learning to use it is important for security and modularity. It is impertinent that you do not lose the private key, as it is irrecoverable.
To get started, follow the instructions below.
- Create a folder.
mkdir -p ~/.config/sops/age
- Generate a private key using
age
nix-shell -p age --run "age-keygen -o ~/.config/sops/age/keys.txt"
OR
Use ssh-to-age to convert id_ed22519 to age.
nix-shell -p ssh-to-age --run "ssh-to-age -private-key -i ~/.ssh/id_ed25519 > ~/.config/sops/age/keys.txt"
There are other ways of generating a private key. Refer to sops-nix. 3. Get a public key.
nix-shell -p age --run "age-keygen -y ~/.config/sops/age/keys.txt"
- On the same directory as
flake.nix, create.sops.yamland paste the following below.
# This example uses YAML anchors which allows reuse of multiple keys
# without having to repeat yourself.
# Also see https://github.com/Mic92/dotfiles/blob/d6114726d859df36ccaa32891c4963ae5717ef7f/nixos/.sops.yaml
# for a more complex example.
keys:
- &admin_alice 2504791468b153b8a3963cc97ba53d1919c5dfd4
- &admin_bob age12zlz6lvcdk6eqaewfylg35w0syh58sm7gh53q5vvn7hd7c6nngyseftjxl
creation_rules:
- path_regex: secrets/[^/]+\.(yaml|json|env|ini)$
key_groups:
- pgp:
- *admin_alice
age:
- *admin_bob
Replace as according to your needs.
5. Create a sops .yaml file.
nix-shell -p sops --run "sops secrets/example.yaml"
NOTE: If you add a new host to your .sops.yaml, you will need to update the keys for all secrets.
nix-shell -p sops --run "sops updatekeys secrets/example.yaml"
Description
Languages
Nix
97.3%
Shell
2.7%