From 429a72accdc4b0674002dd48eaf44439a654cca6 Mon Sep 17 00:00:00 2001 From: Jonni Liljamo Date: Sat, 14 Sep 2024 11:06:48 +0300 Subject: [PATCH] chore: tamma things * rest of hosts * no default actions * add actions via tailscale --- tamma.yaml | 27 ++++++++++++++++++++++++--- 1 file changed, 24 insertions(+), 3 deletions(-) diff --git a/tamma.yaml b/tamma.yaml index 018e8b1..269afb3 100644 --- a/tamma.yaml +++ b/tamma.yaml @@ -1,19 +1,40 @@ # TODO: Somehow auto-generate this via Nix? Since all the hosts are defined there. +# FIXME: This is currently backwards in tamma, fix there... +# Or just remove default actions completely +default_actions: true + +# NOTE: .A.host.Name should match the hostname of the machine, which in turn +# should match the hostname of the machine in my tailnet hosts: - name: alderaan - ip: alderaan + data: + user: root + - name: auth data: user: root - name: cloud - ip: cloud + data: + user: root + - name: dns + data: + user: root + - name: metrics + data: + user: root + - name: proxy data: user: root - name: social - ip: social data: user: root actions: + - name: ssh (tailscale) + exectemplate: ssh {{ .A.host.Data.user }}@{{ .A.host.Name }} + - name: remote rebuild switch (tailscale) + exectemplate: nixos-rebuild switch --flake ".#{{ .A.host.Name }}" --target-host {{ .A.host.Data.user }}@{{ .A.host.Name }} + - name: remote rebuild dry-activate (tailscale) + exectemplate: nixos-rebuild dry-activate --flake ".#{{ .A.host.Name }}" --target-host {{ .A.host.Data.user }}@{{ .A.host.Name }} - name: edit secrets exectemplate: sops secrets/{{ .A.host.Name }}/secrets.yaml -- 2.44.1