my nixos dotfiles :3 (git.koi.rip mirror) git.koi.rip/koi/dotfiles
linux dotfiles neovim nixos catppuccin
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

systems: fix cloudflare token lolz

adam 12595a0d 8f7a4d4f

+19 -4
+1 -1
home/modules/programs/jellyfin-rpc.nix
··· 15 15 }; 16 16 17 17 Service = { 18 - ExecStart = "${pkgs.jellyfin-rpc}/bin/jellyfin-rpc -c /run/user/1000/agenix/jellyfin-rpc"; 18 + ExecStart = "${pkgs.jellyfin-rpc}/bin/jellyfin-rpc -c /run/user/%U/agenix/jellyfin-rpc"; 19 19 Restart = "on-failure"; 20 20 RestartSec = 60; 21 21 };
secrets/cloudflare.pem.age

This is a binary file and will not be displayed.

+2 -1
secrets/secrets.nix
··· 3 3 in 4 4 { 5 5 "chromium.sh.age".publicKeys = [ adam ]; 6 + "cloudflare.pem.age".publicKeys = [ adam ]; 7 + "jellyfin-rpc.json.age".publicKeys = [ adam ]; 6 8 "wakatime.cfg.age".publicKeys = [ adam ]; 7 - "jellyfin-rpc.json.age".publicKeys = [ adam ]; 8 9 }
+16 -2
systems/desktop/default.nix
··· 1 - { pkgs, ... }: 1 + { pkgs, inputs, ... }: 2 2 3 3 { 4 4 imports = [ 5 5 ./hardware-configuration.nix 6 + inputs.agenix.nixosModules.default 6 7 ]; 7 8 8 9 networking.hostName = "desktop"; ··· 43 44 44 45 environment.systemPackages = with pkgs; [ cloudflared ]; 45 46 47 + age.secrets.cloudflare = { 48 + file = ../../secrets/cloudflare.pem.age; 49 + mode = "0400"; 50 + }; 51 + 46 52 systemd.services.cloudflared = { 47 53 description = "cloudflare tunnel"; 48 54 after = [ "jellyfin.service" ]; 49 55 50 - script = "${pkgs.cloudflared}/bin/cloudflared tunnel run --token eyJhIjoiZTcyNjAwOGE4ZmVjNDIwYTNhMDMzZDU2MWNjMGYyZmYiLCJ0IjoiZDUwNTQ4NjktYzEzZC00ZDc4LTk4MjYtOGFhNGJmOWUwOTBiIiwicyI6Ik9UWm1PVEl3WldFdFptVXlOaTAwWWpkbUxUZ3dPVGt0T0RZeFptWmxaREUwWWprMCJ9"; 56 + script = '' 57 + export TUNNEL_ORIGIN_CERT=/run/agenix/cloudflare 58 + 59 + cloudflared=${pkgs.cloudflared}/bin/cloudflared 60 + token=$($cloudflared tunnel token jelly) 61 + 62 + $cloudflared tunnel run --token $token 63 + ''; 64 + 51 65 wantedBy = [ "multi-user.target" ]; 52 66 53 67 serviceConfig = {