Compare commits
4 commits
2eb0b19d8a
...
4b4d3c4425
Author | SHA1 | Date | |
---|---|---|---|
4b4d3c4425 | |||
00d24af03e | |||
33c4a16447 | |||
879481925b |
8 changed files with 67 additions and 7 deletions
42
options/custom/containers/oryx.nix
Normal file
42
options/custom/containers/oryx.nix
Normal file
|
@ -0,0 +1,42 @@
|
||||||
|
{
|
||||||
|
config,
|
||||||
|
inputs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
with lib; let
|
||||||
|
cfg = config.custom.containers.oryx;
|
||||||
|
in {
|
||||||
|
options.custom.containers.oryx.enable = mkOption {default = false;};
|
||||||
|
|
||||||
|
config = mkIf cfg.enable {
|
||||||
|
age.secrets = let
|
||||||
|
secret = filename: {
|
||||||
|
file = "${inputs.self}/secrets/${filename}";
|
||||||
|
};
|
||||||
|
in {
|
||||||
|
"${config.custom.profile}/oryx/.env" = secret "${config.custom.profile}/oryx/.env";
|
||||||
|
};
|
||||||
|
|
||||||
|
#?? arion-oryx pull
|
||||||
|
environment.shellAliases.arion-oryx = "sudo arion --prebuilt-file ${config.virtualisation.arion.projects.oryx.settings.out.dockerComposeYaml}";
|
||||||
|
|
||||||
|
virtualisation.arion.projects.oryx.settings.services = {
|
||||||
|
oryx.service = {
|
||||||
|
container_name = "oryx";
|
||||||
|
env_file = [config.age.secrets."${config.custom.profile}/oryx/.env".path];
|
||||||
|
image = "ossrs/oryx:5";
|
||||||
|
|
||||||
|
ports = [
|
||||||
|
"127.0.0.1:2022:2022" # HTTP
|
||||||
|
"1935:1935" # RTMP
|
||||||
|
"8000:8000/udp" # WebRTC
|
||||||
|
"10080:10080/udp" # SRT
|
||||||
|
];
|
||||||
|
|
||||||
|
restart = "unless-stopped";
|
||||||
|
volumes = ["${config.custom.containers.directory}/oryx/data:/data"];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
|
@ -14,6 +14,8 @@ with lib; let
|
||||||
rm = "${pkgs.coreutils}/bin/rm";
|
rm = "${pkgs.coreutils}/bin/rm";
|
||||||
sway-audio-idle-inhibit = "${pkgs.sway-audio-idle-inhibit}/bin/sway-audio-idle-inhibit";
|
sway-audio-idle-inhibit = "${pkgs.sway-audio-idle-inhibit}/bin/sway-audio-idle-inhibit";
|
||||||
wallpaper = "${config.home-manager.users.${config.custom.username}.home.file.".local/bin/wallpaper".source}";
|
wallpaper = "${config.home-manager.users.${config.custom.username}.home.file.".local/bin/wallpaper".source}";
|
||||||
|
wl-paste = "${pkgs.wl-clipboard}/bin/wl-paste";
|
||||||
|
xclip = "${pkgs.xclip}/bin/xclip";
|
||||||
in {
|
in {
|
||||||
options.custom.desktops.niri.misc = {
|
options.custom.desktops.niri.misc = {
|
||||||
enable = mkOption {default = false;};
|
enable = mkOption {default = false;};
|
||||||
|
@ -59,6 +61,9 @@ in {
|
||||||
]
|
]
|
||||||
++ optionals config.custom.wallpaper [
|
++ optionals config.custom.wallpaper [
|
||||||
{command = [wallpaper];}
|
{command = [wallpaper];}
|
||||||
|
]
|
||||||
|
++ optionals config.custom.desktops.niri.xwayland [
|
||||||
|
{command = [wl-paste "--watch" xclip "-selection" "clipboard"];} # Sync (X)wayland clipboard
|
||||||
];
|
];
|
||||||
|
|
||||||
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsswitch-eventslid-close
|
# https://github.com/sodiboo/niri-flake/blob/main/docs.md#programsnirisettingsswitch-eventslid-close
|
||||||
|
|
|
@ -192,13 +192,22 @@ in {
|
||||||
s = "ssh";
|
s = "ssh";
|
||||||
si = "ssh -o KexAlgorithms=+diffie-hellman-group1-sha1 -o HostkeyAlgorithms=+ssh-rsa -o Ciphers=aes256-cbc";
|
si = "ssh -o KexAlgorithms=+diffie-hellman-group1-sha1 -o HostkeyAlgorithms=+ssh-rsa -o Ciphers=aes256-cbc";
|
||||||
|
|
||||||
ta = "tmux attach";
|
t = "tailscale";
|
||||||
td = "tmux detach";
|
td = "sudo tailscale down";
|
||||||
tk = "tmux kill-session";
|
te = "sudo tailscale exit-node";
|
||||||
tl = "tmux list-sessions";
|
ti = "tailscale ip --4";
|
||||||
|
tl = "sudo tailscale login";
|
||||||
|
tp = "tailscale ping";
|
||||||
|
ts = "tailscale status";
|
||||||
|
tss = "tailscale ssh";
|
||||||
|
tt = "sudo tailscale set";
|
||||||
|
tu = "sudo tailscale up";
|
||||||
|
tw = "sudo tailscale switch";
|
||||||
|
|
||||||
ts = "tailscale";
|
txa = "tmux attach";
|
||||||
tsip = "tailscale ip --4";
|
txd = "tmux detach";
|
||||||
|
txk = "tmux kill-session";
|
||||||
|
txl = "tmux list-sessions";
|
||||||
|
|
||||||
w = "waydroid";
|
w = "waydroid";
|
||||||
wa = "waydroid app";
|
wa = "waydroid app";
|
||||||
|
|
|
@ -67,6 +67,8 @@ in {
|
||||||
allowedUDPPorts = [
|
allowedUDPPorts = [
|
||||||
3478 # TURN
|
3478 # TURN
|
||||||
5349 # TURN
|
5349 # TURN
|
||||||
|
8000 # WebRTC
|
||||||
|
10080 # SRT
|
||||||
];
|
];
|
||||||
|
|
||||||
allowedUDPPortRanges = [
|
allowedUDPPortRanges = [
|
||||||
|
|
|
@ -19,7 +19,8 @@
|
||||||
mastodon.enable = true;
|
mastodon.enable = true;
|
||||||
netbox.enable = true;
|
netbox.enable = true;
|
||||||
#// nextcloud.enable = true;
|
#// nextcloud.enable = true;
|
||||||
owncast.enable = true;
|
oryx.enable = true;
|
||||||
|
#// owncast.enable = true;
|
||||||
#// redlib.enable = true;
|
#// redlib.enable = true;
|
||||||
#// searxng.enable = true;
|
#// searxng.enable = true;
|
||||||
};
|
};
|
||||||
|
|
|
@ -83,6 +83,7 @@ in {
|
||||||
"server/netdata/parent.conf".publicKeys = server;
|
"server/netdata/parent.conf".publicKeys = server;
|
||||||
"server/nextcloud/.env".publicKeys = server;
|
"server/nextcloud/.env".publicKeys = server;
|
||||||
"server/nextcloud/db.env".publicKeys = server;
|
"server/nextcloud/db.env".publicKeys = server;
|
||||||
|
"server/oryx/.env".publicKeys = server;
|
||||||
"server/searxng/.env".publicKeys = server;
|
"server/searxng/.env".publicKeys = server;
|
||||||
"server/users/myned.pass".publicKeys = server;
|
"server/users/myned.pass".publicKeys = server;
|
||||||
"server/users/root.pass".publicKeys = server;
|
"server/users/root.pass".publicKeys = server;
|
||||||
|
|
Binary file not shown.
BIN
secrets/server/oryx/.env
Normal file
BIN
secrets/server/oryx/.env
Normal file
Binary file not shown.
Loading…
Add table
Reference in a new issue