diff options
Diffstat (limited to '')
| -rw-r--r-- | notes/backup_disk.md | 12 | ||||
| -rw-r--r-- | notes/beets_import.md | 8 | ||||
| -rw-r--r-- | notes/deploy.md | 35 | ||||
| -rw-r--r-- | notes/git_crypt.md | 12 | ||||
| -rw-r--r-- | notes/gpg_keys.md | 38 | ||||
| -rw-r--r-- | notes/laptop.md | 12 | ||||
| -rw-r--r-- | notes/names.md | 12 | ||||
| -rw-r--r-- | notes/password.md | 12 | ||||
| -rw-r--r-- | notes/wifi.md | 61 |
9 files changed, 181 insertions, 21 deletions
diff --git a/notes/backup_disk.md b/notes/backup_disk.md index 363bae11..d2e8f12e 100644 --- a/notes/backup_disk.md +++ b/notes/backup_disk.md @@ -1,3 +1,15 @@ +<!-- +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + # How to create a backup disk (for `soispha.services.backup`) ## Find the disk diff --git a/notes/beets_import.md b/notes/beets_import.md deleted file mode 100644 index fb9a9ff6..00000000 --- a/notes/beets_import.md +++ /dev/null @@ -1,8 +0,0 @@ -# How to import an artist into beets - -1. Download said artist (`deerix`) -1. Remove the useless/bad albums of the downloaded artist -1. Check for name duplicates (`./find_duplicates`) -1. Import (`beet import <artist>`) -1. Remove duplicated files (`beet duplicates artist:<artist>`) -1. Search for canonical name duplicates (`beet list artist:<artist> <leftover name>`) diff --git a/notes/deploy.md b/notes/deploy.md new file mode 100644 index 00000000..fa6384f6 --- /dev/null +++ b/notes/deploy.md @@ -0,0 +1,35 @@ +# How to deploy a new host + +1. Boot the minimal nixos-iso and get an ssh shell +1. Perform disk configuration via disko: +```bash +export NIX_CONFIG="experimental-features = nix-command flakes" +nix shell nixpkgs#lix + +sudo --preserve-env=NIX_CONFIG nix run github:nix-community/disko/latest -- --mode destroy,format,mount --flake git+https://git.foss-syndicate.org/bpeetz/nixos-config?ref=prime#apzu + +sudo git clone https://git.foss-syndicate.org/bpeetz/nixos-config /mnt/etc/nixos/ + +sudo nixos-generate-config --root /mnt +sudo nixos-install + +sudo nixos-enter +export NIX_CONFIG="experimental-features = nix-command flakes" +nix shell nixpkgs#lix + +nix shell nixpkgs#git nixpkgs#nvd + +git config --global --add safe.directory /etc/nixos +cd /etc/nixos + +./scripts/build.sh apzu +``` + +```bash +nix run github:nix-community/nixos-anywhere -- \ + --flake "git+https://git.foss-syndicate.org/bpeetz/nixos-config?ref=prime#apzu" \ + --target-host "root@nixos.fritz.box" \ + --build-on local \ + --disko-mode disko \ + --extra-files /tmp/apzu_root +``` diff --git a/notes/git_crypt.md b/notes/git_crypt.md index b123a77b..8c42bb62 100644 --- a/notes/git_crypt.md +++ b/notes/git_crypt.md @@ -1,3 +1,15 @@ +<!-- +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + # What to do, when nix wants to build the locked repository Simply delete the source path: diff --git a/notes/gpg_keys.md b/notes/gpg_keys.md index 39602e3b..4a6fb5d1 100644 --- a/notes/gpg_keys.md +++ b/notes/gpg_keys.md @@ -1,3 +1,15 @@ +<!-- +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + # How to add a comment to gpg keys Export it as follows: @@ -11,38 +23,38 @@ or add it manually, the supported options include (RFC4880): - "Version", which states the OpenPGP implementation and version used to encode the message. -- "Comment", a user-defined comment. OpenPGP defines all text to - be in UTF-8. A comment may be any UTF-8 string. However, the +- "Comment", a user-defined comment. OpenPGP defines all text to + be in UTF-8. A comment may be any UTF-8 string. However, the whole point of armoring is to provide seven-bit-clean data. Consequently, if a comment has characters that are outside the US-ASCII range of UTF, they may very well not survive transport. -- "MessageID", a 32-character string of printable characters. The +- "MessageID", a 32-character string of printable characters. The string must be the same for all parts of a multi-part message - that uses the "PART X" Armor Header. MessageID strings should be + that uses the "PART X" Armor Header. MessageID strings should be unique enough that the recipient of the mail can associate all - the parts of a message with each other. A good checksum or + the parts of a message with each other. A good checksum or cryptographic hash function is sufficient. The MessageID SHOULD NOT appear unless it is in a multi-part - message. If it appears at all, it MUST be computed from the + message. If it appears at all, it MUST be computed from the finished (encrypted, signed, etc.) message in a deterministic - fashion, rather than contain a purely random value. This is to + fashion, rather than contain a purely random value. This is to allow the legitimate recipient to determine that the MessageID cannot serve as a covert means of leaking cryptographic key information. - "Hash", a comma-separated list of hash algorithms used in this - message. This is used only in cleartext signed messages. + message. This is used only in cleartext signed messages. - "Charset", a description of the character set that the plaintext - is in. Please note that OpenPGP defines text to be in UTF-8. An + is in. Please note that OpenPGP defines text to be in UTF-8. An implementation will get best results by translating into and out - of UTF-8. However, there are many instances where this is easier - said than done. Also, there are communities of users who have no + of UTF-8. However, there are many instances where this is easier + said than done. Also, there are communities of users who have no need for UTF-8 because they are all happy with a character set - like ISO Latin-5 or a Japanese character set. In such instances, + like ISO Latin-5 or a Japanese character set. In such instances, an implementation MAY override the UTF-8 default by using this - header key. An implementation MAY implement this key and any + header key. An implementation MAY implement this key and any translations it cares to; an implementation MAY ignore it and assume all text is UTF-8. diff --git a/notes/laptop.md b/notes/laptop.md index 38ae5a24..bc9ddc86 100644 --- a/notes/laptop.md +++ b/notes/laptop.md @@ -1,3 +1,15 @@ +<!-- +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + # backlight Run `ls /sys/class/backlight` to see possible options. diff --git a/notes/names.md b/notes/names.md index 44339580..6906d29e 100644 --- a/notes/names.md +++ b/notes/names.md @@ -1,3 +1,15 @@ +<!-- +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + # Naming scheme The hosts naming scheme follows two list of Mesopotamian (Babylonian) deities: diff --git a/notes/password.md b/notes/password.md index 96366bae..2717af48 100644 --- a/notes/password.md +++ b/notes/password.md @@ -1,3 +1,15 @@ +<!-- +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + # Password Run `nix run n#mkpasswd -- -m yescrypt -s -R 11` diff --git a/notes/wifi.md b/notes/wifi.md new file mode 100644 index 00000000..d27b11b4 --- /dev/null +++ b/notes/wifi.md @@ -0,0 +1,61 @@ +<!-- +nixos-config - My current NixOS configuration + +Copyright (C) 2025 Benedikt Peetz <benedikt.peetz@b-peetz.de> +SPDX-License-Identifier: GPL-3.0-or-later + +This file is part of my nixos-config. + +You should have received a copy of the License along with this program. +If not, see <https://www.gnu.org/licenses/gpl-3.0.txt>. +--> + +# How to set-up “corporate” Wi-Fi with NetworkManager (`nmcli`) + +```bash +nmcli connection add \ +type wifi \ +connection.id "$name_you_want_to_use" \ +wifi.ssid "$actual_ssid" \ +wifi.mode infrastructure \ +wifi-sec.key-mgmt wpa-eap \ +802-1x.eap peap \ +802-1x.identity "$your_login_name" \ +802-1x.phase2-auth mschapv2 + +# Ask, so that `nmcli` can determine your password. +nmcli connection up "$name_you_want_to_use" --ask +``` + +## This will result in a configuration file, similar to this one: + +```ini +[connection] +id="$name_you_want_to_use" +uuid=aaaaaaaa-aaaa-aaaa-aaaa-deadbeef1245 +type=wifi +interface-name=wlo1 + +[wifi] +mode=infrastructure +ssid="$actual_ssid" + +[wifi-security] +key-mgmt=wpa-eap + +[802-1x] +ca-cert=/home/user_name/.local/share/nm/ca-cert.cer +domain-suffix-match=dnsx.topackt.net +eap=peap; +identity="$identity" +phase2-auth=mschapv2 + +[ipv4] +method=auto + +[ipv6] +addr-gen-mode=stable-privacy +method=auto + +[proxy] +``` |
