Automatically track the configuration of each machine in a git branch #119
Loading…
x
Reference in New Issue
Block a user
No description provided.
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
As we change configuration of machines, it becomes harder to know at which commit each machine is. It would be nice to have a branch per machine with the activated config. This way we can:
git diff m/$(hostname) HEADwhich changes I would introduce in the current machine if I ran anixos-rebuild switch.git diff m/hut m/tentshow the differences among machines.git log --graph --allwould show in a single graph where all machines are and which ones need to be updated.This can be implemented with a systemd daemon that runs on activation after the network is ready, using a robot user that has push access to the gitea repository. We can keep a copy of the current configuration in the nix store (including git history) and then push it to the corresponding machine branch.