• Stars
    star
    173
  • Rank 219,014 (Top 5 %)
  • Language
    Nix
  • License
    GNU General Publi...
  • Created almost 4 years ago
  • Updated 2 months ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

My NixOS Configurations

nixos

Configuration checks: Build Status

This repository includes all configurations for my NixOS machines. Feel free to use parts of it as you please, but keep it mind it is intended mostly for personal use. I've written posts about certain aspects of this setup on my personal blog.

Initial Setup

The structure of this repository is meant to allow easy manual deployment. Individual hosts are defined in /machines/<hostname> and will import re-usable parts of the configuration as needed.

Deployment is managed with lollypops Secrets are stored in pass.

TL;DR To use a host configuration on a fresh install, make sure that:

  • The hostname is set correctly (hostname <machine name>)
  • You are connected to the internet and have access rights to the repository
  • Pass has the necessary secrets for the machine
  • The machine's config is up-to-date

Then backup the generated hardware-configuration.nix file:

# Overwrite hardware-configuration.nix file with the generated one
cp /etc/nixos/hardware-configuration.nix \
   ./machines/$(hostname)/hardware-configuration.nix

# Commit and push the new file
git commit -am"Add hardware-configuration for $(hostname)" && git push

TODO: update

It is also possible to build on the system itself when logged in, e.g. to get additional debug information.

cd /var/src/machine-config
sudo nixos-rebuild --flake ".#kartoffel" switch

Current Hosts

Configuration Type Location VPN IP Description
kartoffel Desktop local 192.168.7.3 Desktop
ahorn Desktop local 192.168.7.2 Notebook
birne Server local 192.168.7.4 Local NAS
porree Server netcup.de 192.168.7.1 Server for pablo.tools
mega Server netcup.de 192.168.7.6 Server for megaclan3000.de
kfbox Server netcup.de 192.168.7.5 Server for 0cx.de

The services running on each host are documented in the host-specific README.md files.

Deployment

Default Deployment

Deployment is handled with lollypops.

TODO Update/document

First Deployment

If the system has not been configured to use flakes (e.g. fresh install), the first deployment will have to be build on a machine that has. This can be done from any of the other hosts that have the repository. The configuration will the have the necessary options set, so that flakes works from now on with the normal lollypops deployment.

# bash, zsh doesn't always work correctly
sudo nixos-rebuild --flake .#new-hostname --target-host <new-host-ip> --build-host localhost switch

Contributing?

While contributions don't make much sense for a personal configuration repository, I'm always happy to get hints, tips and constructive criticism. If you find something that could be done in a better way, please let me know!

More Repositories

1

lollypops

Lollypop Operations - NixOS Deployment Tool
Nix
112
star
2

base16-universal-manager

A universal manager to set base16 themes for any supported application
Go
71
star
3

wallpaper-generator

Generate wallpaper images from mathematical functions
Lua
49
star
4

alertmanager-ntfy

Relay prometheus alertmanager alerts to ntfy.sh
Nix
27
star
5

home-assistant-grafana-relay

Use home-assistant notifications for Grafana alerts
Nix
19
star
6

nixos-home

My user setup for [NixOS](nixos.org) Desktops.
Vim Script
19
star
7

woodpecker-flake-pipeliner

Woodpecker configuration Service to dynamically generate pipelines from nix flakes
Nix
18
star
8

nixos-raspi4-template

Genearate NixOS images for Raspberry Pi 4
Nix
18
star
9

go-game-of-life

Golang implementation of Conway's Game of Life
Go
13
star
10

restic-exporter

Prometheus exporter for restic backups (https://restic.net)
Go
10
star
11

gitea-matrix-bot

A bot to post gitea events to a matrix channel
Go
10
star
12

matrix-bot

🍺 πŸ“  *BYOB* (Build your own bot) - Build a matrix bot that acts on !commands
Go
10
star
13

pgp2ssh

Convert PGP/GPG private keys to SSH private keys
Go
10
star
14

dotfiles-awesome

Configuration for the Awesome window manager
Lua
9
star
15

kali-i3

Create Kali Linux VM with i3 using Vagrant and Ansible
Shell
9
star
16

promterm

Show firing Prometheus alerts in the terminal
Rust
5
star
17

dotfiles-emacs

My literate Emacs configuration
Emacs Lisp
5
star
18

wemos-d1-macropad

A 6-key Macropad using a Wemos D1 mini ESP32 and a 3D-printed case
4
star
19

csgo-server-picker

A blocker for specified IPs
Go
3
star
20

nix-apple-fonts

Nix flake for Apple fonts
Nix
3
star
21

nixos-3dprint-raspi

NixOS configuration and image generator for Raspberry to control 3D-printers
Nix
3
star
22

rust-forum

Rust
3
star
23

ansible-backup

Set up Borg backup-script on Linux Arch
Shell
2
star
24

ansible-wireguard-server

Set up a Wireguard Server on Linux Arch
2
star
25

matrix-hook

Matrix webhook receiver for Prometheus/Alertmanager
Nix
2
star
26

nixos-raspberrypi-router

NixOS Router build on the Raspberry Pi Compute Module 4 platfrom
Nix
2
star
27

dotfiles-vim

My (neo)vim configuration
Vim Script
2
star
28

flowscii

Make and edit flowcharts with ascii and unicode characters
Go
2
star
29

dotfiles-ansible

My personal dotfiles, managed with Ansible
Shell
2
star
30

http-stressor

A tool to run stress tests on HTTP services
Go
2
star
31

ondsel-nix

Nix flake for Ondsel built from AppImage releases
Nix
2
star
32

tm-gamepad

Custom gamepad for Trackmania using a Waveshare RP2040-Zero and Lekker analog switches
Python
2
star
33

gopherlix

A Server for the Gopher protocol written in Go
Go
1
star
34

dotfiles-old

My dotfiles
Vim Script
1
star
35

ansible-zsh

My ZSH configuration
Shell
1
star
36

go-treecompare

Compare Hierarchical Trees 🌳
Go
1
star
37

ansible-wireguard-client

Wireguard client setup on Linux Arch
1
star
38

ansible-polybar

My polybar configuration
Shell
1
star
39

openvas-nix

WIP: nix flake for openvas
Nix
1
star
40

ansible-i3

My i3 window manager configuration
Shell
1
star
41

robonet

Convolutional network implementation in Go
Go
1
star
42

i3-layout-selector

Use rofi menu to select saved i3 layouts
Shell
1
star
43

pinpox

Profile readme
Go
1
star
44

bd

Nix
1
star
45

i3-auto-layout

Automatically arrange the i3 windows with pre-defined layouts
Python
1
star
46

efont-unicode

The /efont/ Unicode Bitmap Fonts (mirror)
1
star
47

dotfiles

My managed dotfiles
Shell
1
star
48

http2irc

HTTP to IRC relay bot to announce basend on incoming webhooks
Nix
1
star
49

s3photoalbum

Serve S3-compatible Bucket as photo album
Go
1
star
50

mega_led_3000

Remote + Controller for a RGB LED light Chain.
C++
1
star
51

nixos-caddy-patched

Nix
1
star
52

webhooker

Listen for webhooks, run commands - Webhooker will do for you whatever you want.
Nix
1
star
53

nixos-netcup-demo

Nix
1
star