Compare commits
2 commits
525cc4925a
...
f0c708c93b
Author | SHA1 | Date | |
---|---|---|---|
f0c708c93b | |||
65ab49716f |
5 changed files with 36 additions and 73 deletions
|
@ -1 +0,0 @@
|
||||||
nixos/modules/nixos/services/adguardhome/default.nix:hashicorp-tf-password:47
|
|
|
@ -7,7 +7,7 @@ repos:
|
||||||
hooks:
|
hooks:
|
||||||
- args:
|
- args:
|
||||||
- --config-file
|
- --config-file
|
||||||
- .github/lint/.yamllint.yaml
|
- .yamllint.yaml
|
||||||
id: yamllint
|
id: yamllint
|
||||||
- repo: https://github.com/pre-commit/pre-commit-hooks
|
- repo: https://github.com/pre-commit/pre-commit-hooks
|
||||||
rev: v4.6.0
|
rev: v4.6.0
|
||||||
|
|
27
.yamllint.yaml
Normal file
27
.yamllint.yaml
Normal file
|
@ -0,0 +1,27 @@
|
||||||
|
---
|
||||||
|
ignore: |
|
||||||
|
.direnv/
|
||||||
|
.private/
|
||||||
|
.vscode/
|
||||||
|
*.sops.*
|
||||||
|
|
||||||
|
extends: default
|
||||||
|
|
||||||
|
rules:
|
||||||
|
truthy:
|
||||||
|
allowed-values: ["true", "false", "on"]
|
||||||
|
|
||||||
|
comments:
|
||||||
|
min-spaces-from-content: 1
|
||||||
|
|
||||||
|
line-length: disable
|
||||||
|
|
||||||
|
braces:
|
||||||
|
min-spaces-inside: 0
|
||||||
|
max-spaces-inside: 1
|
||||||
|
|
||||||
|
brackets:
|
||||||
|
min-spaces-inside: 0
|
||||||
|
max-spaces-inside: 0
|
||||||
|
|
||||||
|
indentation: enable
|
74
README.md
74
README.md
|
@ -1,19 +1,5 @@
|
||||||
# jahanson's homelab
|
# jahanson's homelab
|
||||||
|
|
||||||
[Repository Documentation](https://truxnell.github.io/nix-config/)
|
|
||||||
|
|
||||||
## Thank you Truxnell
|
|
||||||
|
|
||||||
Thank you for a lot of the groundwork you laid for the base nixos configuration and a lot of modules!
|
|
||||||
|
|
||||||
## Getting started
|
|
||||||
|
|
||||||
To Install
|
|
||||||
|
|
||||||
```sh
|
|
||||||
nixos-rebuild switch --flake github:jahanson/nix-config-tn#HOST
|
|
||||||
```
|
|
||||||
|
|
||||||
## Goals
|
## Goals
|
||||||
|
|
||||||
- [ ] Learn nix
|
- [ ] Learn nix
|
||||||
|
@ -24,60 +10,14 @@ nixos-rebuild switch --flake github:jahanson/nix-config-tn#HOST
|
||||||
|
|
||||||
## TODO
|
## TODO
|
||||||
|
|
||||||
- [ ] Forgejo Actions
|
- [ x ] Forgejo Actions
|
||||||
- [ ] Bring over hosts
|
- [ ] Bring over hosts
|
||||||
- [ ] git.hsn.dev
|
- [ x ] Varda (forgejo)
|
||||||
- [ ] Telperion (network services)
|
- [ ] Telperion (network services)
|
||||||
- [ ] Gandalf (NixNAS)
|
- [ ] Gandalf (NixNAS)
|
||||||
- [ ] Thinkpad T470
|
- [ x ] Thinkpad T470
|
||||||
|
|
||||||
## Checklist
|
|
||||||
|
|
||||||
### Adding a new node
|
|
||||||
|
|
||||||
- Ensure secrets are grabbed from note and all sops re-encrypte with task sops:re-encrypt
|
|
||||||
- Add to relevant github action workflows
|
|
||||||
- Add to .github/settings.yaml for PR checks
|
|
||||||
|
|
||||||
## Applying configuration changes on a local machine can be done as follows:
|
|
||||||
|
|
||||||
```sh
|
|
||||||
cd ~/dotfiles
|
|
||||||
sudo nixos-rebuild switch --flake .
|
|
||||||
# This will automatically pick the configuration name based on the hostname
|
|
||||||
```
|
|
||||||
|
|
||||||
Applying configuration changes to a remote machine can be done as follows:
|
|
||||||
|
|
||||||
```sh
|
|
||||||
cd ~/dotfiles
|
|
||||||
nixos-rebuild switch --flake .#nameOfMachine --target-host machineToSshInto --use-remote-sudo
|
|
||||||
```
|
|
||||||
|
|
||||||
## Hacking at nix files
|
|
||||||
|
|
||||||
Eval config to see what keys are being set.
|
|
||||||
|
|
||||||
```bash
|
|
||||||
nix eval .#nixosConfigurations.rickenbacker.config.security.sudo.WheelNeedsPassword
|
|
||||||
nix eval .#nixosConfigurations.rickenbacker.config.mySystem.security.wheelNeedsPassword
|
|
||||||
```
|
|
||||||
|
|
||||||
And browsing whats at a certain level in options - or just use [nix-inspect](https://github.com/bluskript/nix-inspect) TUI
|
|
||||||
|
|
||||||
```bash
|
|
||||||
nix eval .#nixosConfigurations.rickenbacker.config.home-manager.users.jahanson --apply builtins.attrNames --json
|
|
||||||
```
|
|
||||||
|
|
||||||
Quickly run a flake to see what the next error message is as you hack.
|
|
||||||
|
|
||||||
```bash
|
|
||||||
nixos-rebuild dry-run --flake . --fast --impure
|
|
||||||
```
|
|
||||||
|
|
||||||
## Links & References
|
## Links & References
|
||||||
|
|
||||||
- [Misterio77/nix-starter-config](https://github.com/Misterio77/nix-starter-configs)
|
- [truxnell/dotfiles](https://github.com//truxnell/nix-config/)
|
||||||
- [billimek/dotfiles](https://github.com/billimek/dotfiles/)
|
- [billimek/dotfiles](https://github.com/billimek/dotfiles/)
|
||||||
- [Erase your Darlings](https://grahamc.com/blog/erase-your-darlings/)
|
|
||||||
- [NixOS Flakes](https://www.tweag.io/blog/2020-07-31-nixos-flakes/)
|
|
||||||
|
|
|
@ -3,12 +3,9 @@
|
||||||
version: "3"
|
version: "3"
|
||||||
|
|
||||||
includes:
|
includes:
|
||||||
sop:
|
sops:
|
||||||
taskfile: ".taskfiles/sops"
|
taskfile: ".taskfiles/sops"
|
||||||
dir: .taskfiles/sops
|
dir: .taskfiles/sops
|
||||||
nix:
|
|
||||||
taskfile: ".taskfiles/nix"
|
|
||||||
dir: "{{.ROOT_DIR}}"
|
|
||||||
pre:
|
pre:
|
||||||
taskfile: ".taskfiles/pre-commit"
|
taskfile: ".taskfiles/pre-commit"
|
||||||
dir: "{{.ROOT_DOR}}"
|
dir: "{{.ROOT_DOR}}"
|
||||||
|
|
Reference in a new issue