Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

All other Modules /

Discuss all other Modules here.

Moderators: martimiz, Sean, biapar, Willr, Ingo, swaiba, simon_w

Subsites - have which url?


Reply


5 Posts   1490 Views

Avatar
Dimi66

Community Member, 3 Posts

6 February 2011 at 12:36am

It must be very, very obvious, because it isn't mentioned anywhere: To which url do I have to point a subsite domain?

Could it be something like www.masterdomain.com/mysilverstripe_dir/mysite/subsites/mysubsitename ? Please help!

The Knowledge Base Link is also broken (as per today).

Avatar
Willr

Forum Moderator, 5513 Posts

6 February 2011 at 11:01am

I assume when you are talking about 'pointing' you mean in your Virtual Hosts configuration (Apache or whatever you're using). You simply point it to the exactly the same folder as you do with your main site. All requests go to the main site then SilverStripe determines what site you meant from the HTTP_HOST header and the available site domains in the database.

Avatar
Dimi66

Community Member, 3 Posts

7 February 2011 at 9:16am

Edited: 07/02/2011 9:46am

Thanks, Willr, I had thought about that, and the reason for doubting that option is, that I tried that and I would always end up with an Error 500. I looked it up again, and it specifies "Init: SSL server IP/port conflict:". Is apache initializing an SSL connection?

The Plesk httpd.include and vhost.conf file entries, which are making the slavedomain.com point to silverstripes root directory:

httpd.include:
<VirtualHost 85.214.102.21:80>
   ServerName slavedomain.com:80
   ServerAlias www.slavedomain.com
...

vhost.conf:
<Directory /srv/www/vhosts/masterdomain.com/httpdocs/silverstripes_root>
Options -Includes -ExecCGI
<IfModule sapi_apache2.c>
php_admin_flag engine on
php_admin_flag safe_mode on
php_admin_value open_basedir "/srv/www/vhosts/masterdomain.com/httpdocs/silverstripes_root"
</IfModule>
<IfModule mod_php5.c>
php_admin_flag engine on
php_admin_flag safe_mode on
php_admin_value open_basedir "/srv/www/vhosts/masterdomain.com/httpdocs/silverstripes_root"
</IfModule>
AllowOverride All
Options +FollowSymLinks +SymLinksIfOwnerMatch
</Directory>
DocumentRoot /srv/www/vhosts/masterdomain.com/httpdocs/silverstripes_root

With Joomla, this vhost redirection is working perfectly. But here with silverstripes, I get only Error 500. Although I have setup subsites correctly and the config mask displays all the domain names, which correspond to the subsite. Anybody can imagine, why SSL connectino is established?

Avatar
Willr

Forum Moderator, 5513 Posts

7 February 2011 at 12:10pm

Do you have a DocumentRoot setup still for your slave? Doesn't appear in httpd.include which I assume it should.

Avatar
Dimi66

Community Member, 3 Posts

7 February 2011 at 10:49pm

>>Do you have a DocumentRoot setup still for your slave? Doesn't appear in httpd.include which I assume it should.

The redirected DocumentRoot statement (httpdocs/silverstripes) in the slavedomain's vhost.conf is automatically included and overwrites the http.include file's DocumentRoot (httpdocs). The http.include must not be altered, because it is overwritten by the Plesk configurator.

After setting up a new domain with Plesk, and creating a specific vhost.conf file (see other post), of course I run both
/usr/local/psa/admin/sbin/websrvmng --reconfigure-vhost --vhost-name=slavedomain.com
and
rcapache2 reload

This works perfectly fine for Joomla JMS multidomain component, which activates the specific slavedomain database, according to the calling domain, but silverstripes comes up with an Error 500, and the mentioned "SSL conflict". I wonder if anybody has experienced same issue.