Vesta Control Panel - Forum

Community Forum

Skip to content

Advanced search
  • Quick links
    • Main site
    • Github repo
    • Google Search
  • FAQ
  • Login
  • Register
  • Board index Dev Section Modification & Patches
  • Search

Patch : force users to add subdomains to their existing main domains only

Section with modification and patches for Vesta
Locked
  • Print view
Advanced search
5 posts • Page 1 of 1
orwah
Posts: 9
Joined: Sat Feb 06, 2016 9:23 pm

Patch : force users to add subdomains to their existing main domains only

Post by orwah » Sat Feb 13, 2016 5:14 pm

VestaCP is great panel
i started using it from short time only.

i faced a small problem in VestaCP:
- normal Users can Add their own "web-domains" ,and Admin can not stop that .
- and they can add subdomains from Main-Domains that belong to OTHER users .

it's nice , but not suetable for all hosting cases .

So i made a small Patch:
thats when Users want to add a new web domain , the panel will force them to append one of their maindomains to the new domain , so it will be subdomain like this : newdomain.maindomain.ltd
so every new domain the user want to add , will be turned to subdomain from one of his existing domains chosen by him (and only from his existing domains) .

Users :
- can't add new web domain.
- can't add subdomain to other user main domain .
- can add subdomains to the one of their existing maindomain only .
- can chose from their main-domains list when adding subdomain .
- removing Aliases for Users .
- change "add web domain" button to "add sub domain".

Admins :
- no changes
- can add web domains to users , without any problems .

IMPORTANT
to try this you must log out from admin account and log in as normal user , if you log from admin account you will not see any change,even if login from Admin->as user , because we need Admin control still the same (so he can add new domains to Users) .

Patch include the old files Backups But it's better to take your own Backups before use, and try on your own responsibility .

tested on Vesta 0.9.8-15 .


* Maybe VestaCp team can try to find complete solution better than this quick & simple small attempt .


Screenshot:
Image

files :
https://bugs.vestacp.com/attachments/do ... omains.zip


regards
Top

AFN
Posts: 43
Joined: Sat Feb 01, 2014 2:03 am

Re: Patch : force users to add subdomains to their existing main domains only

Post by AFN » Fri Feb 19, 2016 2:47 am

Seems nice, but how to I install it?
Top

mike08
Posts: 160
Joined: Sat Jun 20, 2015 7:12 am

Os: Debian 6x
Web: apache + nginx
Re: Patch : force users to add subdomains to their existing main domains only

Post by mike08 » Sat Feb 20, 2016 12:47 pm

AFN wrote:Seems nice, but how to I install it?
Copy the files from the vesta/web directory in the .zip file and paste them into:
/usr/local/vesta/web/
Make sure to backup any file that would be overwritten in case you want to go back to your previous state.
Regards,
Top

skamasle
Collaborator
Posts: 592
Joined: Mon Feb 29, 2016 6:36 pm

Re: Patch : force users to add subdomains to their existing main domains only

Post by skamasle » Wed Mar 09, 2016 3:00 pm

Hi

File was deleted ?

I get 404.
Top

skurudo
VestaCP Team
Posts: 8099
Joined: Fri Dec 26, 2014 2:23 pm
Contact:
Contact skurudo
Website Facebook Google+ Skype
Twitter

Re: Patch : force users to add subdomains to their existing main domains only

Post by skurudo » Wed Feb 14, 2018 9:09 am

Closed due inactivity.
Top


Locked
  • Print view

5 posts • Page 1 of 1

Return to “Modification & Patches”



  • Board index
  • All times are UTC
  • Delete all board cookies
  • The team
Powered by phpBB® Forum Software © phpBB Limited
*Original Author: Brad Veryard
*Updated to 3.2 by MannixMD
 

 

Login  •  Register

I forgot my password