From d2c3751323314974978218fa8fc374c5ee419717 Mon Sep 17 00:00:00 2001 From: Astro Date: Sun, 7 Apr 2019 00:58:42 +0200 Subject: [PATCH] add mucbot container --- hosts/storage-ng/mucbot/configuration.nix | 30 +++++++++++++++++++++++ hq.nixops | 12 +++++++++ secrets | 2 +- 3 files changed, 43 insertions(+), 1 deletion(-) create mode 100644 hosts/storage-ng/mucbot/configuration.nix diff --git a/hosts/storage-ng/mucbot/configuration.nix b/hosts/storage-ng/mucbot/configuration.nix new file mode 100644 index 00000000..07ccd021 --- /dev/null +++ b/hosts/storage-ng/mucbot/configuration.nix @@ -0,0 +1,30 @@ +{ config, pkgs, lib, ... }: + +let + tiggerGit = builtins.fetchTarball https://github.com/astro/tigger/archive/master.tar.gz; +in +{ + imports = + [ ../../../lib/lxc-container.nix + ../../../lib/shared.nix + "${tiggerGit}/module.nix" + ]; + + networking.hostName = "mucbot"; + networking.useNetworkd = true; + networking.defaultGateway = "172.22.99.4"; + networking.useDHCP = lib.mkForce true; + + services.tigger = { + enable = true; + jid = import ../../../secrets/hosts/mucbot/jabber-jid.nix; + password = import ../../../secrets/hosts/mucbot/jabber-password.nix; + muc = "c3d2@chat.c3d2.de/Astrobot"; + }; + + # This value determines the NixOS release with which your system is to be + # compatible, in order to avoid breaking some software such as database + # servers. You should change this only after NixOS release notes say you + # should. + system.stateVersion = "18.09"; # Did you read the comment? +} diff --git a/hq.nixops b/hq.nixops index e186f71c..8b1dc0b2 100644 --- a/hq.nixops +++ b/hq.nixops @@ -24,4 +24,16 @@ storeKeysOnMachine = true; }; }; + + "mucbot" = + { ... }: + { + imports = [ + hosts/storage-ng/mucbot/configuration.nix + ]; + deployment = { + targetHost = "2a02:8106:208:5201:28db:dff:fe6b:e89a"; + storeKeysOnMachine = true; + }; + }; } diff --git a/secrets b/secrets index 57621eb0..ae9bd8f1 160000 --- a/secrets +++ b/secrets @@ -1 +1 @@ -Subproject commit 57621eb036ccaee2ea1af85b31abe93526fd0e79 +Subproject commit ae9bd8f1429a06c819e72266614a382b5bc7cdea