These are step by step instructions to install Wifidog auth-server on Debian Linux (testing, 2.6.17).
December 11th, 2006 - This document is currently a draft and not completed! There might be a lot more package that is really required in the "prerequisites" section.
Install the distro
A minimum install without any specific package is enough, as long as you have internet access and apt installed.
Before we install anything lets be sure we have access to internet and that our apt database is updated
The authentification server require apache and php (we install the latest version)
apt-get install apache2 php5
Database server install
It also require a database server. PostgreSQL 8.1 is available. 8.1 is harder to configure but faster on current computer.
apt-get install postgresql-8.1
Configure PostgreSQL 8.1
If you selected postgresql-8.1, it will crash at install. You must configure postgresql.conf before being able to launch the services.
This isn't a good security setting, you should make sure to configure the whole thing later on! Right now, you need, at least to change:
#listen_addresses='localhost' SSL = true
listen_addresse='*' SSL = false
Install prerequisites - step2
We also need some specifics librairies
apt-get install xml-core gettext mcrypt libapache2-mod-php5 php5-cgi apt-get install php5-mcrypt php5-mhash php5-pgsql php-pear php5-xmlrpc php5-curl
if you are using a current/2011 debian/ubuntu, you have to enable long variable names in suhosin - otherwise php will not work as expected:
vi /etc/php5/apache2/conf.d/suhosin.ini -> add: suhosin.post.max_name_length = 100 -> add: suhosin.request.max_varname_length = 100
To get the latest version of wifidog-auth we will need subversion:
apt-get install subversion
If you want multi-locales support, you will have to install that packages (or configure every one of them).
apt-get install locales-all
Some more libs
pear install XML_RPC cd /tmp wget http://ovh.dl.sourceforge.net/sourceforge/phlickr/Phlickr-0.2.5.tgz pear install Phlickr-0.2.5.tgz rm Phlickr-0.2.5.tgz
Some stuff that isn't needed for the install, but still nice to have on a server (and which won't be install by default). If you don't what these are, you might not need them ;-) Openssh-server will allow you to launch command remotly, very useful for the third screen of install.php
apt-get install openssh-server less
Install the auth server
svn checkout https://dev.wifidog.org/svn/trunk/wifidog-auth mv wifidog-auth/ /var/www/
Apache 2 configuration file
We need to change the document root. We take for granted that this server will be of no other "web" use... if it is, guess you'll have to learn how to configure apache2.
and change (at the fifth line):
remove the rewrite rule around line 17
cd /etc/init.d/ ./apache2 restart
Configure locale in wifidog.conf
If you have installed locales-all and you want to keep the "French" default portal page, this step isn't needed. In other cases: you will have to change the file config.php
on line 208 (ctrl+w+enter, ctrl+t+enter, 208) remplace
Configure mail server
You need to have a valid mailer in order to mail account confirmation!
apt-get install postfix
Select the "internet site with smart host" configuration option and answer the next series of questions.
Configure the auth server
Go to http://your-domaine.com/install.php and follow the instructions. You can follow the following walk-though, under the install step: auth-server. It isn't updated though. Or you can follow the onscreen introduction ;-)
They will ask to :
1) First screen
create a wifidog user in postgres
su - postgres createuser wifidog --pwprompt
IF you have PostgreSQL 8.1 : answer no to the three questions
create a database owned by this new user
createdb wifidog --encoding=UTF-8 --owner=wifidog
you must then
and click next in your browser (it will ask for the password in dog_cookie.txt)
2) Second screen: Verification of the installed software. If you followed this guide, you have everything install (except Radius support).
3) Third screen:
You will have to copy-paste the big serie of command, click refresh and next. The easiest way of doing that is if you have a ssh connection to your box (this is why I proposed openssh-server package earlier)
4) Fourth screen You may need to install Smarty. Let it do that. NEXT.
Click install for simplepie, (you may need to do this manually in your ssh session by changing /branches/ to /releases/ in the failed command from your web console session as the svn repo has changed structure at simplepie.org), then click NEXT.
Click install for feedpressreview, then next.
Click NEXT when asked to install Phlickr (it is already installed, even if the system doesn't see it).
5) Fill out your db information..
Remove installation files
Of course, the only one that should have access to the install.php file is you. You will need to move the file "install.php" out of public sight.
1) Go to your wifidog directory (/var/www/wifidog-auth/wifidog in our case).
2) Move "install.php" file to the parent directory which is not visible to the public:
mv install.php ../install.php
note that you can move it wherever you want, but make sure it's not public.