[Samba] long scripts

David Mulder dmulder at samba.org
Fri Oct 14 14:44:59 UTC 2022

On 10/14/22 8:21 AM, Peter Carlson via samba wrote:
> This is only partly a samba question and more a AD/GPO question
> I would like to have it setup via GPO that users when logging into 
> windows run login.ps1 and when logging in to linux run login.sh
> I have found one solution requiring python to be installed and using 
> one python script to detect the os and then re-act appropriately.  
> However I dont want to install python on windows computers. I was 
> thinking something like if computer in Linux Servers logon script = 
> login.sh otherwise logon script = login.ps1, but I'm not quite sure 
> how to best do this.  Maybe there is already a wiki on this that I 
> can't find?
You could use Samba's client group policy for the linux client:


Only works if you enable it on the client also:


David Mulder
Labs Software Engineer, Samba
1221 S Valley Grove Way, Suite 500
Pleasant Grove, UT 84062
(P)+1 385.208.2989
dmulder at suse.com

More information about the samba mailing list