Limit ISPConfig admin to one domain

Discussion in 'Installation/Configuration' started by MaDJiK, Nov 19, 2014.

  1. MaDJiK

    MaDJiK New Member

    Hello,

    I've done the same on another server, but this time I can't stop ISPConfig from appearing on all domains with :8080
    I just add a server name, it used to work. Do you know what more can I do? :confused: So usually I do:


    Code:
    ######################################################
    # This virtual host contains the configuration
    # for the ISPConfig controlpanel
    ######################################################
    
    Listen 8080
    NameVirtualHost *:8080
    
    <VirtualHost _default_:8080>
      [B]ServerName my_admin_domain.net[/B]
    
     
    Last edited: Nov 19, 2014
  2. till

    till Super Moderator Staff Member ISPConfig Developer

    I guess you changed the ispconfig port on the other server to 443. Or you must have added a efault vhost on port 8080 to catch the requests for other domains.
     
  3. MaDJiK

    MaDJiK New Member


    Thanks again for you time Till. :)

    You're right it seems necessary, but no!
    Here I try to add a first vhost on port 8080, but it catches all! Just like if my ServerName instruction is ignored. :confused:
     
  4. till

    till Super Moderator Staff Member ISPConfig Developer

    Dies the first vhost uses:

    <VirtualHost _default_:8080>

    as well? If you have the IP or * there instead of _default_, it will be a stronger match and catch all requests.
     
  5. MaDJiK

    MaDJiK New Member

    Oh my bad, I find the default vhost with the command apache2ctl -D DUMP_VHOSTS There was an included file, so I recreate a default vhost, and it's OK. :)

    So the good ispconfig.vhost if you want to limit ISPConfig to one domain is:


    Code:
    ######################################################
    # This virtual host contains the configuration
    # for the ISPConfig controlpanel
    ######################################################
    
    Listen 8080
    NameVirtualHost *:8080
    
    
    [B]<VirtualHost *:8080>
    	ServerName 11.22.33.44 (server IP)
    	DocumentRoot /var/www
    	#<Directory /var/www/>
    	#	Options Indexes FollowSymLinks MultiViews
    	#	AllowOverride None
    	#	Order allow,deny
    	#	allow from all
    	#</Directory>
    	# Shows to 403 error, uncomment to read /var/www/
    	SSLEngine on
    	SSLCertificateFile    /etc/ssl/certs/ssl-cert-snakeoil.pem
    	SSLCertificateKeyFile /etc/ssl/private/ssl-cert-snakeoil.key
    </VirtualHost>[/B]
    
    
    <VirtualHost *:8080>
      [B]ServerName my_admin_domain.net[/B]
      ...
    
     
    Last edited: Nov 20, 2014

Share This Page