summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--machines/bismuth/default.nix3
-rw-r--r--modules/sunshine.nix32
2 files changed, 26 insertions, 9 deletions
diff --git a/machines/bismuth/default.nix b/machines/bismuth/default.nix
index a70d93c..2bd6f72 100644
--- a/machines/bismuth/default.nix
+++ b/machines/bismuth/default.nix
@@ -5,8 +5,9 @@
./hardware.nix
./devices.nix
- ../../modules/binary-cache.nix
../../modules/hardware/amd-gpu.nix
+ ../../modules/binary-cache.nix
+ ../../modules/sunshine.nix
];
# expose vm web interface to tailnet
diff --git a/modules/sunshine.nix b/modules/sunshine.nix
index 28ccff8..6889e02 100644
--- a/modules/sunshine.nix
+++ b/modules/sunshine.nix
@@ -17,6 +17,27 @@ let
capitalize = str: toUpper (substring 0 1 str) + substring 1 (-1) str;
user = "mel";
+
+ # per machine sunshine settings
+ perMachine = {
+ # wolfram has an arc b570 gpu optimized for transcoding,
+ # and is the primary streaming machine
+ wolfram = {
+ adapter_name = "/dev/dri/renderD128"; # primary card should be located here
+ encoder = "vaapi"; # or "qsv" is quicksync is better supported
+ av1_mode = 2;
+ };
+
+ # bismuth has a radeon rx 9070 xt, and is only
+ # used when streaming from wolfram is impossible,
+ # as it's my personal desktop machine.
+ bismuth = {
+ adapter_name = "/dev/dri/renderD128"; # primary card should be located here
+ encoder = "amdvce";
+ av1_mode = 0;
+ hevc_mode = 2;
+ };
+ };
in
{
services.sunshine = {
@@ -28,19 +49,14 @@ in
settings = {
sunshine_name = capitalize me.name;
- # note: these are the settings for wolfram and it's intel arc b570 gpu
- # in particular, should be adjusted for different setups when used!
- adapter_name = "/dev/dri/renderD128"; # primary card should be located here
- encoder = "vaapi"; # or "qsv" is quicksync is better supported
- av1_mode = 2;
-
# no need for encryption since we are going through a secure network anyway
lan_encryption_mode = 0;
wan_encryption_mode = 0;
origin_web_ui_allowed = "wan"; # allow access everywhere
- gamepad = "ds5"; # my primary controllers
- };
+ gamepad = "auto"; # to support ds5 and steam deck controllers
+ }
+ // perMachine.${me.name};
applications = {
env = {