tsuki: add maunium stickerpickers

This commit is contained in:
Oystein Kristoffer Tveit 2023-01-03 22:45:41 +01:00
parent 2e3c8631fe
commit 3d088d73be
Signed by: oysteikt
GPG Key ID: 9F2F7D8250F35146
3 changed files with 65 additions and 34 deletions

View File

@ -35,6 +35,10 @@
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
maunium-stickerpicker = {
url = "git+file:///home/h7x4/git/maunium-stickerpicker-nix";
};
vscode-server = { vscode-server = {
url = "github:msteen/nixos-vscode-server"; url = "github:msteen/nixos-vscode-server";
flake = false; flake = false;
@ -61,6 +65,7 @@
vscode-server, vscode-server,
secrets, secrets,
fonts, fonts,
maunium-stickerpicker,
dotfiles, dotfiles,
website website
}: let }: let

View File

@ -0,0 +1,52 @@
# This is imported directly by the nginx config
{ lib, maunium-stickerpicker }: let
inherit (maunium-stickerpicker.outputs) createStickerPickerWithStickers;
inherit (maunium-stickerpicker.outputs.fetchers) fetchFromChatStickers;
in {
stickers-h7x4 = createStickerPickerWithStickers {
homeserver = "https://matrix.nani.wtf";
userId = "@stickerbot1:nani.wtf";
accessToken = "syt_c3RpY2tlcmJvdDE_KMDwLEdAdPswTXPhCoeN_3FSt8B";
packs = [
{
title = "Dogboy";
sha256 = "RTyxgVzwUPSyPLeiFp7bQ4X5DgEaHB/+dPPPc5w2Cfw=";
src = fetchFromChatStickers {
name = "dog-cat-dogboy-side-1";
sha256 = "PNqTMxm7iUFxObkAZURHxMxBMmUerugoRTA4IsO1aJ8=";
};
}
{
title = "Frown Cat 2";
sha256 = "pNFtjoxSRLDsL9UxwX/crRcx6qHNKmXhhYU7+ygEJHE=";
src = fetchFromChatStickers {
name = "frown-cat-vol-2-1";
sha256 = "E2n9PfL8pxIalam7+89emqCfKsoa/emNiBS93b0q9Ro=";
};
}
];
};
stickers-pingu = createStickerPickerWithStickers {
homeserver = "https://matrix.nani.wtf";
userId = "@stickerbot1:nani.wtf";
accessToken = "syt_c3RpY2tlcmJvdDE_KMDwLEdAdPswTXPhCoeN_3FSt8B";
packs = [
{
title = "Catgirl";
sha256 = "UBU1cNYDnhPjStHGVNcTa8MpLeYHr1qn7Ea1jmB1hJ0=";
src = fetchFromChatStickers {
name = "dog-cat-catgirl-side-1";
sha256 = "HNU49j9ju+UH8AiN0/sQIMgTNfNuZ/Xbpli2yisighg=";
};
}
{
title = "Frown Cat 1";
sha256 = "uJ6O7fDLBS/I9EiU1oIieDzbyrr9IPbaWF5pGDmwYZo=";
src = fetchFromChatStickers {
name = "frown-cat-1";
sha256 = "rapDLBSWvxrvbp4E4/zzUM0IU6OALdAk1jA/1PP3LhY=";
};
}
];
};
}

View File

@ -62,7 +62,7 @@
subdomains: url: extraSettings: subdomains: url: extraSettings:
host subdomains (recursiveUpdate { locations."/".proxyPass = url; } extraSettings); host subdomains (recursiveUpdate { locations."/".proxyPass = url; } extraSettings);
in (listToAttrs [ in (listToAttrs ([
{ {
name = "nani.wtf"; name = "nani.wtf";
value = { value = {
@ -113,40 +113,14 @@
}) })
# (host ["vpn"] "" {}) # (host ["vpn"] "" {})
(proxy ["hydra"] "http://localhost:${s ports.hydra}" {}) (proxy ["hydra"] "http://localhost:${s ports.hydra}" {})
(proxy ["air"] "https://${ips.kansei}:${s ports.kansei}" {}) ] ++ (let
stickerpickers = pkgs.callPackage ../matrix/maunium-stickerpicker.nix {
# (proxy ["sync" "drive"] "" {}) inherit (inputs) maunium-stickerpicker;
# (proxy ["music" "mpd"] "" {})
]) // {
# Disabled for time being
# ${config.services.jitsi-meet.hostName} = {
# enableACME = true;
# forceSSL = true;
# };
}; };
in [
upstreams = {}; (host ["stickers-pingu"] { root = "${stickerpickers.stickers-pingu}/"; })
(host ["stickers-h7x4"] { root = "${stickerpickers.stickers-h7x4}/"; })
streamConfig = '' ])));
upstream minecraft {
server ${ips.crafty}:${s ports.minecraft};
}
server {
listen 0.0.0.0:${s ports.minecraft};
listen [::0]:${s ports.minecraft};
proxy_pass minecraft;
}
'';
# upstream openvpn {
# server localhost:${s ports.openvpn};
# }
# server {
# listen 0.0.0.0:${s ports.openvpn};
# listen [::0]:${s ports.openvpn};
# proxy_pass openvpn;
# }
}; };
networking.firewall.allowedTCPPorts = [ networking.firewall.allowedTCPPorts = [