Quercus: Wordpress Mu

From Resin 3.0

Revision as of 01:00, 2 July 2008 by Emil (Talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to: navigation, search


Running Wordpress Mu 1.5.1 on Resin 3.2.0

WordPress Mu is a multi-user version of WordPress that allows for several different blogs to be maintained side-by-side in a single deployment. It also offers management capabilities for handling the different blogs. Blogs can appear as different virtual hosts or in sub-paths. This page shows how to install WordPress Mu using virtual hosts.

Requirements

  1. MySQL server
  2. Java 1.5 or higher
  3. Access to your DNS server

Full installation

  1. Download WordPress Mu 1.5.1 from http://mu.wordpress.org/download/
  2. Download Resin 3.2.0 from http://www.caucho.com/download
  3. Unzip Resin 3.2.0 in /usr/local/share
  4. Copy /usr/local/share/resin-3.2.0/conf/resin.xml to /etc/resin/resin.xml
  5. Edit /etc/resin/resin.xml to listen to port 80:
    <http address="*" port="80"/>
  6. Edit /etc/resin/resin.xml to allow for wildcard virtual hosts by changing the default <host> tag to:
    <host regexp="(.*)example\.com">
    <host-name>${host.regexp[1]}example.com</host-name>
    <web-app id="/" root-directory="/var/www/hosts/default/webapps/ROOT"/>
    <web-app id="/resin-admin" root-directory="${resin.home}/php/admin">
    <!--
    - Administration application /resin-admin
    -->
    <prologue>
    <resin:set var="resin_admin_external" value="false"/>
    <resin:set var="resin_admin_insecure" value="true"/>
    </prologue>
    </web-app>
    </host>
  7. Create a virtual host directory for your domain:
    /var/www/hosts/default/webapps/ROOT
  8. Unzip WordPress Mu and copy all files and directories to /var/www/hosts/default/webapps/ROOT
  9. Create the WordPress database:
    mysql -u root
    mysql> CREATE DATABASE wordpress;
  10. Create the directory /var/www/hosts/default/webapps/ROOT/WEB-INF/lib
  11. Download MySQL Connector/J 5.1.6 (http://dev.mysql.com/downloads/connector/j/5.1.html)
  12. Unzip MySQL Connector/J and place the mysql-connector-java-5.1.6-bin.jar in /var/www/hosts/blog.example.com/webapps/ROOT/WEB-INF/lib
  13. Create the file /var/www/hosts/default/webapps/ROOT/WEB-INF/resin-web.xml:
    <?xml version="1.0"?>
    <web-app xmlns="http://caucho.com/ns/resin">
    <welcome-file-list>
    <welcome-file>index.php</welcome-file>
    </welcome-file-list>
    <rewrite-dispatch>
    <!-- uploaded files -->
    <forward full-url-regexp="^(.*/)?files/$"
    target="index.php"/>
    <forward full-url-regexp="^(.*/)?files/(.*)"
    target="wp-content/blogs.php?file=$2"/>
    <!-- pass through requests that go to real files -->
    <dispatch>
    <when exists="$0"/>
    </dispatch>
    <forward full-url-regexp="^([_0-9a-zA-Z-]+/)?(wp-.*)" target="$2"/>
    <forward full-url-regexp="^([_0-9a-zA-Z-]+/)?(.*\.php)$" target="$2"/>
    <!-- send all other requests to index.php -->
    <forward target="/index.php"/>
    </rewrite-dispatch>
    </web-app>
  14. Run
    java -jar /usr/local/share/resin-3.2.0/lib/resin.jar -conf /etc/resin/resin.conf start
  15. Browse to your host and set up WordPress Mu according to the online directions
Personal tools