migrated scripts to separate flake
This commit is contained in:
@@ -1,4 +1,5 @@
|
||||
{
|
||||
inputs,
|
||||
lib,
|
||||
config,
|
||||
pkgs,
|
||||
@@ -6,7 +7,7 @@
|
||||
}:
|
||||
let
|
||||
cfg = config.my.servers.jellyfin;
|
||||
sub-sync = pkgs.writeScriptBin "sub-sync" (builtins.readFile ../../scripts/sub-sync.sh);
|
||||
sub-sync = inputs.jawz-scripts.packages.x86_64-linux.sub-sync;
|
||||
sub-sync-path = [
|
||||
pkgs.nix
|
||||
pkgs.bash
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
{
|
||||
inputs,
|
||||
lib,
|
||||
config,
|
||||
pkgs,
|
||||
@@ -260,9 +261,7 @@ in
|
||||
nextcloud-cron.path = [ pkgs.perl ];
|
||||
nextcloud-cronjob =
|
||||
let
|
||||
nextcloud-cronjob = pkgs.writeScriptBin "nextcloud-cronjob" (
|
||||
builtins.readFile ../../scripts/nextcloud-cronjob.sh
|
||||
);
|
||||
nextcloud-cronjob = inputs.jawz-scripts.packages.x86_64-linux.nextcloud-cronjob.sh;
|
||||
in
|
||||
{
|
||||
description = "Runs various nextcloud-related cronjobs";
|
||||
|
||||
22
modules/servers/plex-discord-bot.nix
Normal file
22
modules/servers/plex-discord-bot.nix
Normal file
@@ -0,0 +1,22 @@
|
||||
{ lib, config, ... }:
|
||||
let
|
||||
cfg = config.my.servers.plex-discord-bot;
|
||||
setup = import ./setup.nix { inherit lib config; };
|
||||
name = "plex-discord-bot";
|
||||
in
|
||||
{
|
||||
options.my.servers.plex-discord-bot = setup.mkOptions name name 0;
|
||||
config = {
|
||||
virtualisation.oci-containers.containers.plex-discord-bot = lib.mkIf cfg.enable {
|
||||
image = "ghcr.io/phin05/discord-rich-presence-plex:latest";
|
||||
environment = {
|
||||
DRPP_UID = toString config.users.users.jawz.uid;
|
||||
DRPP_GID = toString config.users.groups.users.gid;
|
||||
};
|
||||
volumes = [
|
||||
"${config.my.containerData}/drpp:/app/data"
|
||||
"/run/user/${toString config.users.users.jawz.uid}:/run/app"
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user