Anchor CMS
Anchor CMS and Blog System
Basic installation of the anchor blog, version 0.9.2 with apache and mysql
Configuration summary
Amazon 2014.03.2
Package httpd install
Files
/etc/httpd/conf.d/anchor.conf ensure file exist
<VirtualHost _default_:80> DocumentRoot /var/www/blog/anchor-cms-0.9.2/ <Directory /var/www/> Options Indexes FollowSymLinks MultiViews AllowOverride All Order allow,deny allow from all </Directory> </VirtualHost>
/var/www/blog/anchor-cms-0.9.2/.htaccess ensure file exist
Options -indexes <IfModule mod_rewrite.c> RewriteEngine On RewriteBase / # Allow any files or directories that exist to be displayed directly RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d # Rewrite all other URLs to index.php/URL RewriteRule ^(.*)$ index.php/$1 [L] </IfModule> <IfModule !mod_rewrite.c> ErrorDocument 404 index.php </IfModule>
/var/www/blog ensure directory exist
/var/www/blog/anchor-cms-0.9.2 ensure directory exist
/etc/httpd/conf.d/welcome.conf remove
/var ensure directory exist
Hooks
Post install-anchor-cms
- parameter 1: http://anchorcms.com/download#!/bin/bash set -ue unzip $1 -d /var/www/blog/ chown apache:apache -R /var/www/blog service httpd restart
Package mysql-server install
Hooks
Post configure-database
#!/bin/bash set -ue service mysqld restart echo "CREATE DATABASE anchor;" | mysql