feat: channel-logger-bot initial
This commit is contained in:
parent
72dae4c786
commit
904e298f33
3 changed files with 38 additions and 0 deletions
|
@ -30,6 +30,7 @@
|
|||
./containers/zond
|
||||
./containers/teisu.nix
|
||||
./containers/bots/pcre-sub-bot.nix
|
||||
./containers/bots/channel-logger-bot.nix
|
||||
./vms/hass.nix
|
||||
./vms/bnuuy.nix
|
||||
# ./vms/windows.nix
|
||||
|
|
37
hosts/koi/containers/bots/channel-logger-bot.nix
Normal file
37
hosts/koi/containers/bots/channel-logger-bot.nix
Normal file
|
@ -0,0 +1,37 @@
|
|||
{ abs, config, ... }:
|
||||
|
||||
let
|
||||
secrets = import (abs "lib/secrets.nix");
|
||||
|
||||
UID = 1105;
|
||||
in {
|
||||
imports = [
|
||||
(secrets.declare [{
|
||||
name = "channel-logger-bot-env";
|
||||
owner = "channel-logger-bot";
|
||||
}])
|
||||
];
|
||||
|
||||
users.groups.channel-logger-bot = {};
|
||||
users.users.channel-logger-bot = {
|
||||
group = "channel-logger-bot";
|
||||
isNormalUser = true;
|
||||
uid = UID;
|
||||
};
|
||||
|
||||
virtualisation.oci-containers.containers.channel-logger-bot = {
|
||||
image = "ghcr.io/teidesu/channel-logger-bot:latest";
|
||||
volumes = [
|
||||
"/srv/channel-logger-bot:/app/bot-data"
|
||||
];
|
||||
environmentFiles = [
|
||||
(secrets.file config "channel-logger-bot-env")
|
||||
];
|
||||
environment.MTCUTE_LOG_LEVEL = "5";
|
||||
user = builtins.toString UID;
|
||||
};
|
||||
|
||||
systemd.tmpfiles.rules = [
|
||||
"d /srv/channel-logger-bot 0755 ${builtins.toString UID} ${builtins.toString UID} -"
|
||||
];
|
||||
}
|
BIN
secrets/channel-logger-bot-env.age
Normal file
BIN
secrets/channel-logger-bot-env.age
Normal file
Binary file not shown.
Loading…
Reference in a new issue