-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathserver-role.patch
More file actions
31 lines (31 loc) · 1.74 KB
/
server-role.patch
File metadata and controls
31 lines (31 loc) · 1.74 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
--- samba-4.7.4/packaging/systemd/smb.service.in.orig 2017-12-26 18:26:31.457609415 +0100
+++ samba-4.7.4/packaging/systemd/smb.service.in 2017-12-26 18:27:11.460942304 +0100
@@ -8,6 +8,7 @@
PIDFile=@PIDDIR@/smbd.pid
LimitNOFILE=16384
EnvironmentFile=-@SYSCONFDIR@/sysconfig/samba
+ExecStartPre=/bin/sh -c '[ "`samba-tool testparm --parameter-name="server role" 2>/dev/null | tail -1`" != "active directory domain controller" ]'
ExecStart=@SBINDIR@/smbd --foreground --no-process-group $SMBDOPTIONS
ExecReload=/bin/kill -HUP $MAINPID
LimitCORE=infinity
--- samba-4.7.4/packaging/systemd/nmb.service.in.orig 2017-12-26 18:26:31.457609415 +0100
+++ samba-4.7.4/packaging/systemd/nmb.service.in 2017-12-26 18:27:32.350942051 +0100
@@ -7,6 +7,8 @@
Type=notify
PIDFile=@PIDDIR@/nmbd.pid
EnvironmentFile=-@SYSCONFDIR@/sysconfig/samba
+ExecStartPre=/bin/sh -c '[ "`samba-tool testparm --parameter-name="server role" 2>/dev/null | tail -1`" != "active directory domain controller" ]'
+ExecStartPre=/bin/sh -c '[ "`testparm -s --parameter-name="disable netbios" 2>/dev/null`" != "Yes" ]'
ExecStart=@SBINDIR@/nmbd --foreground --no-process-group $NMBDOPTIONS
ExecReload=/bin/kill -HUP $MAINPID
LimitCORE=infinity
--- samba-4.7.4/packaging/systemd/samba.service.in.orig 2017-12-26 18:26:31.457609415 +0100
+++ samba-4.7.4/packaging/systemd/samba.service.in 2017-12-26 18:27:52.774275149 +0100
@@ -8,6 +8,7 @@
PIDFile=@PIDDIR@/samba.pid
LimitNOFILE=16384
EnvironmentFile=-@SYSCONFDIR@/sysconfig/samba
+ExecStartPre=/bin/sh -c '[ "`samba-tool testparm --parameter-name="server role" 2>/dev/null | tail -1`" = "active directory domain controller" ]'
ExecStart=@SBINDIR@/samba --foreground --no-process-group $SAMBAOPTIONS
ExecReload=/bin/kill -HUP $MAINPID
@systemd_samba_extra@