Import Virtual Server from command line


I'm trying to create virtual server for existing linux user. This can be done through GUI from "Import Virtual Server" tab but there is no option to Import Virtual Server from command line. I can only use migrate-domain from command line and for that i need backup file from other web panels, and i dont have access to any of this backup files. Dont know why there is no Import Virtual Server option from command line, ewery other function that can be done through GUI can be done with command line.

If there is any other way to create virtual server for existing user from shell please let me know.




Yeah, this is a missing feature currently .. command-line importing isn't support yet.

How many users are you looking to import though, and what features do they have enabled (website, DNS domain, etc..) ?

It's not more then 100 users. I wont to make a script so i can execude it from game panel. I'm creating users with game panel and after that i wish to create Webmin, Website, Domain, Logrotate, Mysql, Virus and Spam scanning for that user. This would be easy with virtualmin import-domain support, and create-domain wont let me create domain for existing user. Now i have to manualy create virtual servers as my billing system doesn't support Virtualmin bridge but supports Game Panel. It would be nice to automate game server and virtual server creation. I'm trying to modify virtualmin users files and make a script to copy modifyed files to /etc/webmin/virtual-server/domains/ for new users, but as i can see this is pain in the ass. If I manage to do this I can enable feauters for that domain from command line and i think virtualmin will automaticly create all enabled feautors. Properly you are going to say this is a bad idea, but this is the only solution that i have for now.

O yeah, nice hack and it works:-). There is only missing for parameter. I can also enable features for that account with that script. I knowed that there is a way to execude cgi script from shell but did not know how until now.

Thanks for help