Can't access admin side with ForceVirtualHost=true

Author Message

Erik Weinmaster

Wednesday 06 April 2011 6:46:37 am

I am trying to setup eZ Publish 4.4 on a shared hosting plan with fastcgi. As per the recommendation from André R. I followed a lot of the advice from this posting: http://share.ez.no/forums/install-configuration/possible-to-remove-path-to-ez-index.php-under-fastcgi/%28language%29/eng-GB.

This works fine for my frontend. I use the url www.mysite.com and have successfully removed the index.php? element in the url.

However, now that I have switched ForceVirtualHost=true, I can't access the admin side. What I would like is to use a subdomain of www.admin.mysite.com. This is different from the link I mentioned earlier since that was setup to use www.mysite.com/cms (for the backend).

In short, what do I add to HostMatchMapItems under settings/override/site.ini.append.php? And do I forward the subdomain to www.mysite.com/cms or does ez publish take care of that?

Thanks

-erik

Nicolas Pastorino

Wednesday 06 April 2011 9:03:00 am

I just pinged a knowledgeable one on this, he might step-by !

--
Nicolas Pastorino
Director Community - eZ
Member of the Community Project Board

eZ Publish Community on twitter: http://twitter.com/ezcommunity

t : http://twitter.com/jeanvoye
G+ : http://plus.tl/jeanvoye

André R.

Wednesday 06 April 2011 12:08:50 pm

As mentioned before in some other thread, fastcgi was not supported properly before 4.5.

So best resource for earlier versions are searching for cgi in the forums.

eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom

Erik Weinmaster

Friday 08 April 2011 7:16:09 am

I thought I would follow up since I found a decent solution to running 4.4 with php fastcgi. First you need to run it as uri (MatchOrder=uri). After that all one needs are these rewrite rules in .htaccess:

RewriteEngine On
RewriteRule index_treemenu.php - [L]
RewriteRule content/treemenu/? /index_treemenu.php [L]
RewriteRule ^var/storage/.* - [L]
RewriteRule ^var/[^/]+/storage/.* - [L]
RewriteRule ^var/([^/]+/)?cache/(texttoimage|public)/.* - [L]
RewriteRule ^design/[^/]+/(stylesheets|images|javascript)/.* - [L]
RewriteRule ^share/icons/.* - [L]
RewriteRule ^extension/[^/]+/design/[^/]+/(stylesheets?|images?|javascript|flash|lib?)/.* - [L]
RewriteRule ^packages/styles/.+/(stylesheets|images|javascript)/[^/]+/.* - [L]
RewriteRule ^packages/styles/.+/thumbnail/.* - [L]
RewriteRule ^favicon\.ico - [L]
RewriteRule ^robots\.txt - [L]
RewriteRule .* index.php

These rules will remove the index.php from the url. Since fastcgi will use index.php? in the url, once this is removed, everything seems to work.

Powered by eZ Publish™ CMS Open Source Web Content Management. Copyright © 1999-2014 eZ Systems AS (except where otherwise noted). All rights reserved.

eZ debug

Timing: Jan 18 2025 10:30:52
Script start
Timing: Jan 18 2025 10:30:52
Module start 'layout'
Timing: Jan 18 2025 10:30:52
Module start 'content'
Timing: Jan 18 2025 10:30:53
Module end 'content'
Timing: Jan 18 2025 10:30:53
Script end

Main resources:

Total runtime0.8342 sec
Peak memory usage4,096.0000 KB
Database Queries62

Timing points:

CheckpointStart (sec)Duration (sec)Memory at start (KB)Memory used (KB)
Script start 0.00000.0059 589.1797152.6406
Module start 'layout' 0.00590.0038 741.820339.5000
Module start 'content' 0.00970.8230 781.3203594.0000
Module end 'content' 0.83280.0014 1,375.320312.1250
Script end 0.8342  1,387.4453 

Time accumulators:

 Accumulator Duration (sec) Duration (%) Count Average (sec)
Ini load
Load cache0.00390.4700160.0002
Check MTime0.00130.1505160.0001
Mysql Total
Database connection0.00080.099410.0008
Mysqli_queries0.778293.2865620.0126
Looping result0.00060.0663600.0000
Template Total0.797595.620.3988
Template load0.00170.203220.0008
Template processing0.795895.397620.3979
Template load and register function0.00020.020510.0002
states
state_id_array0.00200.234010.0020
state_identifier_array0.00130.154920.0006
Override
Cache load0.00140.1732330.0000
Sytem overhead
Fetch class attribute can translate value0.00060.075630.0002
Fetch class attribute name0.00100.117860.0002
XML
Image XML parsing0.00130.160230.0004
class_abstraction
Instantiating content class attribute0.00000.001560.0000
General
dbfile0.00180.2197230.0001
String conversion0.00000.001240.0000
Note: percentages do not add up to 100% because some accumulators overlap

Templates used to render the page:

UsageRequested templateTemplateTemplate loadedEditOverride
1node/view/full.tplfull/forum_topic.tplextension/sevenx/design/simple/override/templates/full/forum_topic.tplEdit templateOverride template
4content/datatype/view/ezxmltext.tpl<No override>extension/community_design/design/suncana/templates/content/datatype/view/ezxmltext.tplEdit templateOverride template
5content/datatype/view/ezxmltags/paragraph.tpl<No override>extension/ezwebin/design/ezwebin/templates/content/datatype/view/ezxmltags/paragraph.tplEdit templateOverride template
2content/datatype/view/ezimage.tpl<No override>extension/sevenx/design/simple/templates/content/datatype/view/ezimage.tplEdit templateOverride template
1content/datatype/view/ezxmltags/line.tpl<No override>design/standard/templates/content/datatype/view/ezxmltags/line.tplEdit templateOverride template
1print_pagelayout.tpl<No override>extension/community/design/community/templates/print_pagelayout.tplEdit templateOverride template
 Number of times templates used: 14
 Number of unique templates used: 6

Time used to render debug report: 0.0001 secs