fix smb, manual jellyfin
This commit is contained in:
@@ -203,8 +203,8 @@ in
|
|||||||
enable = true;
|
enable = true;
|
||||||
allowPing = true;
|
allowPing = true;
|
||||||
extraCommands = ''iptables -t raw -A OUTPUT -p udp -m udp --dport 137 -j CT --helper netbios-ns'';
|
extraCommands = ''iptables -t raw -A OUTPUT -p udp -m udp --dport 137 -j CT --helper netbios-ns'';
|
||||||
allowedTCPPorts = [ 80 443 445 139 ];
|
allowedTCPPorts = [ 80 443 ];
|
||||||
allowedUDPPorts = [ 80 443 137 138 ];
|
allowedUDPPorts = [ 80 443 ];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -2,22 +2,23 @@
|
|||||||
|
|
||||||
{
|
{
|
||||||
# Jellyfin
|
# Jellyfin
|
||||||
|
# Nix
|
||||||
|
# environment.systemPackages = [
|
||||||
|
# pkgs.jellyfin
|
||||||
|
# pkgs.jellyfin-web
|
||||||
|
# pkgs.jellyfin-ffmpeg
|
||||||
|
# ];
|
||||||
|
|
||||||
environment.systemPackages = [
|
# services.jellyfin = {
|
||||||
pkgs.jellyfin
|
# enable = true;
|
||||||
pkgs.jellyfin-web
|
# user = "911";
|
||||||
pkgs.jellyfin-ffmpeg
|
# group = "1000";
|
||||||
];
|
# # dataDir = "/mnt/Safe\ SSD/ssd_app_data/jellyfin/config"; # defaults to /var/lib/jellyfin and cannot be changed....
|
||||||
|
# openFirewall = true;
|
||||||
|
|
||||||
services.jellyfin = {
|
# };
|
||||||
enable = true;
|
|
||||||
user = "911";
|
|
||||||
group = "1000";
|
|
||||||
# dataDir = "/mnt/Safe\ SSD/ssd_app_data/jellyfin/config"; # defaults to /var/lib/jellyfin and cannot be changed....
|
|
||||||
openFirewall = true;
|
|
||||||
|
|
||||||
};
|
|
||||||
|
|
||||||
|
# nix-docker
|
||||||
# virtualisation.oci-containers.containers."jellyfin" = {
|
# virtualisation.oci-containers.containers."jellyfin" = {
|
||||||
# autoStart = true;
|
# autoStart = true;
|
||||||
# image = "linuxserver/jellyfin";
|
# image = "linuxserver/jellyfin";
|
||||||
@@ -38,4 +39,37 @@
|
|||||||
# PGID = "1000";
|
# PGID = "1000";
|
||||||
# };
|
# };
|
||||||
# };
|
# };
|
||||||
|
|
||||||
|
# Manual
|
||||||
|
systemd.services.jellyfin-nvidia-docker = {
|
||||||
|
path = [ pkgs.bash ];
|
||||||
|
script = ''
|
||||||
|
set -e
|
||||||
|
exec podman run \
|
||||||
|
--rm \
|
||||||
|
--gpus all \
|
||||||
|
--runtime=nvidia \
|
||||||
|
--name='jellyfin' \
|
||||||
|
--log-driver=journald \
|
||||||
|
--cidfile=/run/podman-'jellyfin'.ctr-id \
|
||||||
|
--cgroups=no-conmon \
|
||||||
|
--sdnotify=conmon \
|
||||||
|
-d \
|
||||||
|
--replace \
|
||||||
|
-e 'JELLYFIN_LOG_DIR'='/log' \
|
||||||
|
-e 'NVIDIA_DRIVER_CAPABILITIES'='compute,utility' \
|
||||||
|
-e 'NVIDIA_VISIBLE_DEVICES'='all' \
|
||||||
|
-e 'PGID'='1000' \
|
||||||
|
-e 'PUID'='911' \
|
||||||
|
-p '8096:8096' \
|
||||||
|
-v '/mnt/Safe SSD/ssd_app_data/jellyfin/config:/config' \
|
||||||
|
-v '/mnt/Safe SSD/ssd_app_data/jellyfin/cache:/cache' \
|
||||||
|
-v '/mnt/Safe SSD/ssd_app_data/jellyfin/log:/log' \
|
||||||
|
-v '/mnt/Main Pool/Movies:/movies' \
|
||||||
|
-v '/mnt/Main Pool/TV:/tv' \
|
||||||
|
linuxserver/jellyfin \
|
||||||
|
'';
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,10 +1,11 @@
|
|||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
{
|
{
|
||||||
services.samba-wsdd = {
|
|
||||||
# make shares visible for Windows clients
|
# make shares visible for Windows clients
|
||||||
|
services.samba-wsdd = {
|
||||||
enable = true;
|
enable = true;
|
||||||
openFirewall = true;
|
openFirewall = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
services.samba = {
|
services.samba = {
|
||||||
enable = true;
|
enable = true;
|
||||||
securityType = "user";
|
securityType = "user";
|
||||||
@@ -17,14 +18,14 @@
|
|||||||
#use sendfile = yes
|
#use sendfile = yes
|
||||||
#max protocol = smb2
|
#max protocol = smb2
|
||||||
# note: localhost is the ipv6 localhost ::1
|
# note: localhost is the ipv6 localhost ::1
|
||||||
hosts allow = 10.0.1 127.0.0.1 localhost
|
hosts allow = 10.0.1. 127.0.0.1 localhost
|
||||||
hosts deny = 0.0.0.0/0
|
hosts deny = 0.0.0.0/0
|
||||||
guest account = nobody
|
guest account = nobody
|
||||||
map to guest = bad user
|
map to guest = bad user
|
||||||
'';
|
'';
|
||||||
shares = {
|
shares = {
|
||||||
backup = {
|
backup = {
|
||||||
path = "/mnt/Main\ Pool/backup";
|
path = "/mnt/Main\ Pool/Backup";
|
||||||
browseable = "yes";
|
browseable = "yes";
|
||||||
"read only" = "no";
|
"read only" = "no";
|
||||||
"guest ok" = "yes";
|
"guest ok" = "yes";
|
||||||
|
|||||||
Reference in New Issue
Block a user