Vesta 2.0 is coming soon! See our progress update: https://vestacp.com/docs/vesta-2-update
Script to list all web domains, mail domains, databases on the server
Script to list all web domains, mail domains, databases on the server
Hi,
I had to write this for a client with a load of users and sites, so I thought I'd just release it here. Its not particularly well written or formatted, but it just lists the info I needed in a single command, and it might save someone some time. Feel free to improve upon it, or suggest additional info.
I had to write this for a client with a load of users and sites, so I thought I'd just release it here. Its not particularly well written or formatted, but it just lists the info I needed in a single command, and it might save someone some time. Feel free to improve upon it, or suggest additional info.
Code: Select all
#!/bin/bash
for USER in $( v-list-users plain | awk '{print $1}' )
do
COUNTWEB=$(v-list-web-domains $USER plain | awk '{print $1}' | wc -l )
COUNTMAIL=$(v-list-mail-domains $USER plain | awk '{print $1}' | wc -l )
COUNTDB=$(v-list-databases $USER plain | awk '{print $1}' | wc -l )
echo "======== $USER ======== "
echo " -- Web Domains ($COUNTWEB): --"
v-list-web-domains $USER plain | awk '{print $1}'
echo " -- Mail Domains ($COUNTMAIL): --"
v-list-mail-domains $USER plain | awk '{print $1}'
echo " -- Databases ($COUNTDB): --"
v-list-databases $USER plain | awk '{print $1}'
echo ""
done
Re: Script to list all web domains, mail domains, databases on the server
This is great and very useful for me, thanks!