From 12105207ea5ccd36096be0be9228190d832a4ce6 Mon Sep 17 00:00:00 2001 From: Alexis Gavoty Date: Sat, 26 Oct 2013 21:50:36 +0200 Subject: [PATCH] Samba fixes... --- yunohost_tools.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/yunohost_tools.py b/yunohost_tools.py index ba2d72a9..9c4e32e1 100644 --- a/yunohost_tools.py +++ b/yunohost_tools.py @@ -242,6 +242,10 @@ def tools_postinstall(domain, password, dyndns=False): # Set hostname to avoid amavis bug if os.system('hostname -d') != 0: os.system('hostname yunohost.yunohost.org') + + # Samba sh*t fix + os.system('net setlocalsid $(ldapsearch -x -b "dc=yunohost,dc=org" -LLL "(objectclass=sambaDomain)" | grep SID | awk \'{print $2}\')') + os.system('smbpasswd -w yunohost') # Create SSL CA ssl_dir = '/usr/share/yunohost/yunohost-config/ssl/yunoCA'