improve PS2 handling
This commit is contained in:
parent
486ce8557b
commit
4c12928356
61
samba.nix
61
samba.nix
@ -2,34 +2,63 @@
|
||||
|
||||
{
|
||||
|
||||
users.users.samba = {
|
||||
isSystemUser = true;
|
||||
description = "Samba User";
|
||||
extraGroups = [ "samba" ];
|
||||
};
|
||||
|
||||
services.samba = {
|
||||
enable = true;
|
||||
securityType = "user";
|
||||
extraConfig = ''
|
||||
workgroup = WORKGROUP
|
||||
server string = smbnix
|
||||
netbios name = smbnix
|
||||
security = user
|
||||
#use sendfile = yes
|
||||
#max protocol = smb2
|
||||
min protocol = NT1
|
||||
hosts allow = 192.168.0 localhost
|
||||
hosts deny = 0.0.0.0/0
|
||||
guest account = nobody
|
||||
map to guest = bad user
|
||||
workgroup = WORKGROUP
|
||||
server string = PS2 Samba Server
|
||||
server role = standalone server
|
||||
max log size = 0
|
||||
|
||||
# Disable printers.
|
||||
load printers = no
|
||||
printing = bsd
|
||||
printcap name = /etc/printcap
|
||||
printcap cache time = 0
|
||||
disable spoolss = yes
|
||||
|
||||
pam password change = yes
|
||||
map to guest = bad user
|
||||
usershare allow guests = yes
|
||||
create mask = 0664
|
||||
force create mode = 0664
|
||||
directory mask = 0775
|
||||
force directory mode = 0775
|
||||
force user =
|
||||
force group = users
|
||||
|
||||
# ===========================
|
||||
# PlayStations 2 OPL settings
|
||||
# ===========================
|
||||
# Lower the minimum protocol to NT1 (a SMB1 dialect), this is required since
|
||||
# Samba 4.11 changed the default and deprecated SMB1.
|
||||
# See https://github.com/ifcaro/Open-PS2-Loader/issues/86 and
|
||||
# https://github.com/ps2dev/ps2sdk/issues/72 for future SMB2 support.
|
||||
server min protocol = NT1
|
||||
server signing = disabled
|
||||
smb encrypt = disabled
|
||||
socket options = TCP_NODELAY TCP_KEEPIDLE=20 IPTOS_LOWDELAY SO_KEEPALIVE
|
||||
|
||||
# Disable keepalive to avoid hanging onto locks. Should not be needed
|
||||
# due to SO_KEEPALIVE and helps with FMV audio stutter.
|
||||
keepalive = 0
|
||||
'';
|
||||
shares = {
|
||||
public = {
|
||||
PS2SMB = {
|
||||
"comment" = "PlaStation 2";
|
||||
path = "/mnt/ps2";
|
||||
browseable = "yes";
|
||||
"read only" = "no";
|
||||
"guest ok" = "yes";
|
||||
"public" = "yes";
|
||||
"available" = "yes";
|
||||
"create mask" = "0644";
|
||||
"directory mask" = "0755";
|
||||
"force user" = "username";
|
||||
"force group" = "groupname";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user