• Halloween is coming! To celebrate the occasion, we dusted off a couple of old skins, and even created a brand new one (Pixel).
    To get into the festive spirit, install the Skins extension.
  • The new Python extension is now available. It allows customers to deploy and manage WSGI-based Python applications on their websites directly from Plesk.
  • The Plesk Mobile apps for iOS and Android and the Plesk Mobile Center extension have been deprecated, and are no longer available for new installations. In Plesk Obsidian 18.0.84, the Plesk Mobile Center extension will be removed from servers during the upgrade, and the Plesk Mobile apps will lose their server management features.
  • The Social Login extension has been deprecated and will be removed in Plesk Obsidian 18.0.84. After that, it will no longer be possible to log in to Plesk with a Google, Facebook, GitHub account, or with a passkey. Plesk usernames and passwords, as well as logging in with a WebPros Account, are not affected.

Script to enable desktop and domain alias for domain users

JLChafardet

Regular Pleskian
this is a little script i just wrote, to let you all (ofcourse i wrote it to save my time) save time if you want to enable the desktop feature and domain alias to your domains.

[root@swordfish ~]# cat desktop_alias_enabler.sh
#!/bin/bash
ls -la /home/httpd/vhosts/|grep ^d|grep -v " \."|cut -c 57- > /root/domains.txt
for line in `cat /root/domains.txt`
do
/usr/local/psa/bin/./domuser.sh -u $line -manage_dashboard true
/usr/local/psa/bin/./domuser.sh -u $line -dashboard true
/usr/local/psa/bin/./domuser.sh -u $line -manage_domain_aliases true
done

[root@swordfish ~]#

PHP:
#!/bin/bash
ls -la /home/httpd/vhosts/|grep ^d|grep -v " \."|cut -c 57- > /root/domains.txt
for line in `cat /root/domains.txt`
do
/usr/local/psa/bin/./domuser.sh -u $line -manage_dashboard true
/usr/local/psa/bin/./domuser.sh -u $line -dashboard true
/usr/local/psa/bin/./domuser.sh -u $line -manage_domain_aliases true
done

Please do the following:

nano desktop_alias_enabler.sh
copy and paste the script above pasted
CTRL+X
Y
ENTER
chmod +x desktop_alias_enabler.sh

sh desktop_alias_enabler.sh

I hope you all find it as usefull as it was for me (saved me HOURS) of work.

Regards,
 
Why would you go through the trouble of using the API when you can just select all your clients with one check box, hit Group Operations, click the Enable radio button on Domain Alias Management, click the radio button on Desktop Management, and hit OK?
 
good point for "clients"

but not for domains.

my script enables the function in a domain basis, try to do what you just told me to do, via "group operations".

cheers.
 
I guess you use something I don't. Setting it for all my clients is all I needed to do.
 
Back
Top