eZ Community » Forums » eZ Publish 5 Platform » Multisites in ezpublish 5 - complete...
expandshrink

Multisites in ezpublish 5 - complete instruction needed

Multisites in ezpublish 5 - complete instruction needed

Monday 09 September 2013 4:46:21 pm - 3 replies

Hello,

I was very pleased to know that there is a possibility to create multisites in ezpublish 5.1 https://confluence.ez.no/display/EZP/Multisite+using+content_root

I followed the page's recommendations and added the siteaccess to ezpublish.yml (I use ezpublish5_community_project-2013.06, ezdemo site with content):

 ezpublish:
    siteaccess:
        default_siteaccess: eng
        list:
            - ezdemo_site
            - ezdemo_site2
            - eng
            - ita
            - ezdemo_site_admin
        groups:
            ezdemo_site_group:
                - ezdemo_site
                - ezdemo_site2
                - eng
                - ita
                - ezdemo_site_admin
        match:
            URIElement: '1'
            Map\Host:
                ezpublish.rhel6: ezdemo_site
                site2.ezpublish.rhel6: ezdemo_site2

and the setting for the siteaccess for the existing location (of type Landing Page):

 ezdemo_site2:

 
            content:
                tree_root:
                    # Root locationId. Default is top locationId
                    location_id: 74
                    # Every URL aliases starting with those prefixes will be considered
                    # being outside of the subtree starting at root_location.
                    # Default value is an empty array.
                    # Prefixes are not case sensitive.
                    excluded_uri_prefixes: [ /media, /images ]

And as result I received 500 Internal Server Error - ezpContentNotFoundException for the http://site2.ezpublish.rhel6/ URL.

What else should be done?

What should I do in order to use another twig template for the second siteaccess?

There are a number of instructions for ezpublish 4 but non for ezpublish5. I would highly appreciate if you could clarify this for me. And I think it would be also useful for other ezpublish 5 newcomers.

Modified on Monday 09 September 2013 4:47:58 pm by Aliaksei Novikau

Tuesday 10 September 2013 12:17:58 pm

I got a similar ezpContentNotFoundException at the beginning of using eZ 5 when I was confused about the difference between "content" and "location". Maybe this is also your mistake. Please make sure you use the node ID (now called "location ID" ) instead of the object ID (now called "content ID" ).

See https://confluence.ez.no/pages/viewpage.action?pageId=2720567

Modified on Tuesday 10 September 2013 12:18:21 pm by Ryad-Marcel El-Dajani

Tuesday 10 September 2013 2:37:39 pm

Thanks Ryad-Marcel!

This id (74 in my case) is the node (location) id. The thing is that the content.tree_root.location_id setting works for the default siteaccess ezdemo_site. But results in error for the ezdemo_site2 siteaccess. Actually the ezdemo_site2 siteaccess can not be found from the admin interface.

So it seems I need to add the new siteaccess in the old 4.x ezpublish manner. But what is new in multisite creation for 5.x ezpublish? The new extra settings? happy.gif Emoticon

And again, it is not clear how to make separate twig templates for the second site.

Tuesday 10 September 2013 5:48:26 pm

Hi

The siteaccess issue in admin is probably related to https://jira.ez.no/browse/EZP-21463

However, your issue is not about this. I guess your configuration is kinda wrong on this. It would be nice to post your whole configuration in a gist (that you can embed here then).

expandshrink

You must be logged in to post messages in this topic!

36 542 Users on board!

Forums menu

Proudly Developed with from