[Samba] is it possible to define default -H and -k yes for samba-tool where required?
Jason Keltz
jas at eecs.yorku.ca
Thu Mar 25 14:02:32 UTC 2021
Hi..
Is there a way to make it so that "samba-tool" uses a default -H option,
and -k yes where applicable via a default option in smb.conf?
It would be really nice to be able to use samba-tool on any machine in
the domain, but I have to remember to attach the -H ldap://dc1 and -k
yes after the command *if it applies*.
I can't just script samba-tool to say, /opt/samba/bin/samba-tool $* -H
ldap://dc1 -k yes because even the default "samba-tool" invocation which
produces help wouldn't work then since it recognizes that -H and -k in
this case are bogus:
I tried this for fun:
#!/bin/sh
if [ $# -lt 2 ]; then
/opt/samba/bin/samba-tool $*
else
/opt/samba/bin/samba-tool $* -H ldap://dc1 -k yes
fi
... which does work a lot better, but still fails in many cases.
It seems like something that would be useful.
Jason.
More information about the samba
mailing list