| | 1 | = Multi Site WordPress = |
| | 2 | This article describes what I did to set up a multi site Wordpress system running CentOS 7 using the RPM's available from EPEL. |
| | 3 | {{{ |
| | 4 | yum install httpd wordpress mariadb-server |
| | 5 | }}} |
| | 6 | |
| | 7 | Create the database |
| | 8 | {{{ |
| | 9 | mysql -u root -p |
| | 10 | CREATE DATABASE wordpress; |
| | 11 | CREATE USER wordpress@localhost IDENTIFIED BY 'password'; |
| | 12 | GRANT ALL PRIVILEGES ON wordpress.* TO wordpress@localhost IDENTIFIED BY 'password'; |
| | 13 | FLUSH PRIVILEGES; |
| | 14 | exit |
| | 15 | }}} |
| | 16 | |
| | 17 | |
| | 18 | Edit /etc/wordpress/wp-settings.php and include new salts generated here: https://api.wordpress.org/secret-key/1.1/salt/ |
| | 19 | |
| | 20 | Put in the following snippet before /* That's all, stop editing! Happy blogging. */ |
| | 21 | {{{ |
| | 22 | define( 'WP_ALLOW_MULTISITE', true ); |
| | 23 | define('MULTISITE', true); |
| | 24 | define('SUBDOMAIN_INSTALL', true); |
| | 25 | define('DOMAIN_CURRENT_SITE', 'dev.jorritsma.cc'); |
| | 26 | define('PATH_CURRENT_SITE', '/'); |
| | 27 | define('SITE_ID_CURRENT_SITE', 1); |
| | 28 | define('BLOG_ID_CURRENT_SITE', 1); |
| | 29 | define('COOKIE_DOMAIN', $_SERVER['HTTP_HOST']); |
| | 30 | }}} |