Files and permissions when installing SilverStripeFiles and permissions when installing SilverStripe

Posted February 20th, 2010 in SilverStripe

When you open up your web browser to a SilverStripe install for the first time there's an installation process that needs to be run. This requires several permissions to be set correctly when running on a *nix based host so this post has the commands needed to quickly make these permissions correct, and then switch them back and clean up the redundant files afterwards.

Before running the install process

Change to the root directory of the unpacked SilverStripe install and run the following commands:

chmod 0777 assets assets/*
chmod 0666 .htaccess mysite/_config.php assets/*/*

Next, set up the database and users permissions using phpMyAdmin, the MySQL CLI or other tool. And finally, open up the website in your browser, add the database details, the initial administrator and click the install button

After running the install process

After the install process has completed, go back to the command line and do the following for SilverStripe 2.3:

rm -f ChangeLog COPYING INSTALL install.php Makefile rewritetest.php UPGRADING assets/Uploads/SilverStripeLogo.png

And the following for SilverStripe 2.4:

rm -f .mergesources.yml ChangeLog config-form.html COPYING INSTALL install.php Makefile rewritetest.php UPGRADING web.config assets/Uploads/SilverStripeLogo.png

At the time of writing this post, SilverStripe 2.4 is at beta 1 so the files to be deleted above are subject to change.

Other stuff

Don't forget to change the favicon.ico and add a robots.txt. It doesn't even matter if the robots.txt file is blank; at least it will stop a bunch of 404 errors being logged from search engine bots requesting it. To create the blank file do this:

touch robots.txt

Other files and directories to delete include any of the themes that you don't intend using.

Related posts:

Comments

blog comments powered by Disqus