forked from HaakonME/hubzilla
-
Notifications
You must be signed in to change notification settings - Fork 0
Simple VM install
ken restivo edited this page Nov 29, 2015
·
15 revisions
Simple (for me, anyway) install of Hubzilla into a VM or VPS
This will install hubzilla from git into /home/src/hubzilla on Apache2 with MySQL and PHP5.
Table of Contents generated with DocToc
- Install a VM of Debian Jessie or recent Ubuntu 14.04 etc
- Install and set up the basics
- Set up apache
- Set up the database
- Open a webbrowser, hit the URL of the vm
- Make the docs
- Go back to a webbrowser, and configure the rest of the site from the UI.
Installing a VM is beyond the scope of this document, but it's not too hard.
- I do my work logged in via ssh as a regular user, and I use sudo, so this assumes you have that set up. Example of how to set that up might be, as root:
apt-get install sudo openssh-server
useradd -m myregularusername # assuming you didn't already add it during Debian standard install
useradd -G sudo myregularusername
Then ssh in as myregularusername or whatever.
sudo apt-get install screen vim mtr-tiny tree # these are my personal preferences, not really needed
sudo apt-get install apache2 apache2-utils libapache2-mod-php5 php5 php-pear php5-xcache php5-curl php5-mcrypt php5-xdebug php5-mysql mysql-server mysql-client git php5-gd
sudo php5enmod mcrypt
sudo mkdir /home/src
sudo chown `whoami`:`whoami` /home/src
cd /home/src/
git clone https://github.com/redmatrix/hubzilla
cd hubzilla/
mkdir -p "store/[data]/smarty3"
chmod -R 777 store
util/add_addon_repo https://github.com/redmatrix/hubzilla-addons.git matrix
sudo a2enmod rewrite
sudo chgrp www-data ../hubzilla/
sudo chmod g+rwx ../hubzilla/
sudo sh -c "echo \"*/10 * * * * www-data cd /home/src/hubzilla; /usr/bin/php include/poller.php\" > /etc/cron.d/hubzilla"
sudo service cron restart
sudo service apache2 restart
sudo mv /etc/apache2/sites-available/000-default.conf /etc/apache2/sites-available/original-default.conf
sudo vi /etc/apache2/sites-available/000-default.conf
Use this very basic conf
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /home/src/hubzilla
<Directory /home/src/hubzilla/ >
Options Indexes FollowSymLinks
AllowOverride All
Allow from All
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
CustomLog ${APACHE_LOG_DIR}/access.log combined
</VirtualHost>
Then restart apache
sudo service apache2 restart
myqsl -uroot -ppassword
Where "password" is whatever root password you set up when installing the mysql package, and there must be no space between the -p and the password.
Then do this in the mysql shell:
create database hubzilla;
GRANT ALL PRIVILEGES ON hubzilla.* to hubzilla@'%' identified by 'password';
GRANT ALL PRIVILEGES ON hubzilla.* to hubzilla@'localhost' identified by 'password';
And exit mysql.
- Deal with any breakage showing up in the checkboxes. Note that if DNS is messed up, it'll show up as a problem with the .htaccess config! That's because the installer can't AJAX in to the hostname if it won't resolve. Be aware.
- Set up the database in the UI
You will want them, and having them local is nice.
cd /home/src/hubzilla; util/importdoc
That's it. There may be other steps I left out but this was the fastest path from zero to a hubzilla test site for me.