summaryrefslogtreecommitdiff
path: root/file_server
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2021-01-11 16:24:23 +0100
committerAndrew Bartlett <abartlet@samba.org>2021-04-28 03:43:34 +0000
commitceccb6182072ec3ec7d1fe2fc3b85ad140a9e407 (patch)
treea10b4bba4d68d4260aa37bafaa034790f8921155 /file_server
parentd45eddb585ca3c6d4f1a165eaa2e2f5d766faef4 (diff)
downloadsamba-ceccb6182072ec3ec7d1fe2fc3b85ad140a9e407.tar.gz
file_server: Pass the 'samba' daemon config file to smbd
Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Diffstat (limited to 'file_server')
-rw-r--r--file_server/file_server.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/file_server/file_server.c b/file_server/file_server.c
index 91c3147734c..b55f13f5687 100644
--- a/file_server/file_server.c
+++ b/file_server/file_server.c
@@ -58,6 +58,7 @@ static NTSTATUS s3fs_task_init(struct task_server *task)
struct tevent_req *subreq;
const char *smbd_path;
const char *smbd_cmd[2] = { NULL, NULL };
+ const char *config_file = "";
task_server_set_title(task, "task[s3fs_parent]");
@@ -67,6 +68,15 @@ static NTSTATUS s3fs_task_init(struct task_server *task)
}
smbd_cmd[0] = smbd_path;
+ if (!is_default_dyn_CONFIGFILE()) {
+ config_file = talloc_asprintf(task,
+ "--configfile=%s",
+ get_dyn_CONFIGFILE());
+ if (config_file == NULL) {
+ return NT_STATUS_NO_MEMORY;
+ }
+ }
+
/* the child should be able to call through nss_winbind */
(void)winbind_on();
/* start it as a child process */
@@ -75,6 +85,7 @@ static NTSTATUS s3fs_task_init(struct task_server *task)
"-D",
"--option=server role check:inhibit=yes",
"--foreground",
+ config_file,
debug_get_output_is_stdout()?"--log-stdout":NULL,
NULL);
/* the parent should not be able to call through nss_winbind */