diff options
author | NeilBrown <neilb@suse.com> | 2016-12-17 13:03:08 -0500 |
---|---|---|
committer | Steve Dickson <steved@redhat.com> | 2016-12-20 13:29:04 -0500 |
commit | bcf954a7c1f735147355f3aac7dea4ff34046d6f (patch) | |
tree | 588726cac80912fc14b5711186e43ac77a31f78c | |
parent | 8bffe8c5ec1a82d4cb8e57cb8afc5a3571b0f947 (diff) | |
download | nfs-utils-bcf954a7c1f735147355f3aac7dea4ff34046d6f.tar.gz nfs-utils-bcf954a7c1f735147355f3aac7dea4ff34046d6f.tar.xz nfs-utils-bcf954a7c1f735147355f3aac7dea4ff34046d6f.zip |
svcgssd: add /etc/nfs.conf support
Signed-off-by: NeilBrown <neilb@suse.com>
Signed-off-by: Steve Dickson <steved@redhat.com>
-rw-r--r-- | systemd/nfs.conf.man | 9 | ||||
-rw-r--r-- | utils/gssd/svcgssd.c | 14 | ||||
-rw-r--r-- | utils/gssd/svcgssd.man | 17 |
3 files changed, 40 insertions, 0 deletions
diff --git a/systemd/nfs.conf.man b/systemd/nfs.conf.man index 938b970..91c49a0 100644 --- a/systemd/nfs.conf.man +++ b/systemd/nfs.conf.man @@ -208,6 +208,15 @@ See for details. .TP +.B svcgssd +Recognized values: +.BR principal . + +See +.BR rpc.svcgssd (8) +for details. + +.TP .B exportfs Only .B debug= diff --git a/utils/gssd/svcgssd.c b/utils/gssd/svcgssd.c index 0fe7c6d..1fb579a 100644 --- a/utils/gssd/svcgssd.c +++ b/utils/gssd/svcgssd.c @@ -61,6 +61,9 @@ #include "svcgssd.h" #include "gss_util.h" #include "err_util.h" +#include "conffile.h" + +char *conf_path = NFS_CONFFILE; void sig_die(int signal) @@ -98,6 +101,17 @@ main(int argc, char *argv[]) extern char *optarg; char *progname; char *principal = NULL; + char *s; + + conf_init(); + + s = conf_get_str("svcgssd", "principal"); + if (!s) + ; + else if (strcmp(s, "system")== 0) + get_creds = 0; + else + principal = s; while ((opt = getopt(argc, argv, "fivrnp:")) != -1) { switch (opt) { diff --git a/utils/gssd/svcgssd.man b/utils/gssd/svcgssd.man index 7b2de6b..15ef4c9 100644 --- a/utils/gssd/svcgssd.man +++ b/utils/gssd/svcgssd.man @@ -45,6 +45,23 @@ Use the system default credentials .RI (host/ FQDN @ REALM ) rather than the default .RI nfs/ FQDN @ REALM . +.SH CONFIGURATION FILE +Some of the options that can be set on the command line can also be +controlled through values set in the +.B [svcgssd] +section of the +.I /etc/nfs.conf +configuration file. Values recognized include: +.TP +.B principal +If set to +.B system +this is equivalent to the +.B -n +option. If set to any other value, that is used like the +.B -p +option. + .SH SEE ALSO .BR rpc.gssd(8), .SH AUTHORS |