Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In with Facebook Sign In with Google Sign In with OpenID Sign In with Twitter

In this Discussion

Installing Vanilla into subdirectory, but serving from documentroot

Hi all.

I'm attempting to install Vanilla into a subdirectory of my websites document root, but to serve it from the docroot.

Why would I want to do this?

To try and make upgrades as easy as possible with git.

I've checked out vanilla into a subrepository so that I can pull down updates and keep everything in sync with latest release tags. Because I don't want to modify any of the original files, I've duplicated the index.php file and the conf directory and moved them into the document root.

This gives me the following file structure:

  • index.php
  • conf/...
  • vanilla/...

Then in index.php, I've added the following constant at the top:

define('PATH_CONF', __DIR__.'/conf');

I've also updated the PATH_ROOT constant:

define('PATH_ROOT', __DIR__.'/vanilla');

This then allows me to make any config changes I need in a directory outside of the subrepository.

So I'm basically wondering, are there any other config variables or constants (and possibly files) that I may need to alter? Because at the moment, when trying to use the installer, the themes, images and CSS for the page seem to be ignoring the PATH_ROOT constant, and trying to serve files from the document root rather than /vanilla.

Is this even possible? - I guess this is also an important question to be asking!

My aim is to have my configuration and themes outside of the main vanilla repository, which I want to leave as, vanilla (pun intended) as possible.

Answers

Sign In or Register to comment.