Creating Neo
net install
To begin with, you'll need a Debian network install CD. You can download the .iso from here and burn it to a CD in minutes. Be sure to select the right file to match the hardware you are using. Neo is 32-bit intel, so I chose debian-7.8.0-i386-netinst.iso.
Boot from the CD, and respond to the prompts.
- hostname: neo
- domain: richmond.ml
- root password: (blank) yes, that means leave it blank
- user: admin1
- password: ***** (such words are censored)
- guided partitioning:
- use the whole disk
- all files in one partition
- write to disk
- yes
- mirror site: Positive-Internet
- proxy info: (blank)
- select software to install
- NO: Desktop
- YES: Web server
- YES: Print server
- NO: SQL database
- YES: DNS server
- YES: File server
- YES: Mail server
- YES: SSH server
- NO: Laptop
- YES: System utilities
Log in as admin1
Let it reboot, then it prompts for a login
neo login: admin1
password: *****
Add users
sudo adduser andres
password *****
Name, room, phone... (blank)
Same for other users: arthur, dan, ianb....
Set a static IP on the LAN
sudo vi /etc/network/interfaces
delete or comment out the eth0 dhcp line
add instead:
iface eth0 inet static address 192.168.1.40 netmask 255.255.255.0 network 192.168.1.0 broadcast 192.168.1.255 gateway 192.168.1.1
Set up DNS Resolution
sudo vi /etc/resolv.conf
Assuming you're not doing any DNS-related things specific to your local network, you can use Google's public DNS servers
replace the contents of this file with:
nameserver 8.8.8.8 nameserver 8.8.4.4
Install MySQL and PHP
sudo apt-get update
sudo apt-get install mysql-server
- password for mysql admin root user: *****
sudo apt-get install php5 php-pear php5-mysql
sudo apt-get install phpmyadmin
- webserver to run phpadmin: apache2
- configure database? YES, password: *****
- password for phpadmin register with server: (blank)
Configure virtual hosts
cd /etc/apache2/sites-available
sudo cp 000-default 001-neo
sudo vi 001-neo
insert new lines:
ServerName neo.richmondmakerlabs.uk ServerAlias neo
change lines to:
DocumentRoot /var/www/public_html Directory / AllowOverride All Directory /var/www/public_html AllowOverride All
sudo cp 001-neo 002-littlehouse
change lines to:
ServerName littlehouse.richmondmakerlabs.uk ServerAlias littlehouse
sudo cp 001-neo 003-kit
change lines to:
ServerName kit.richmondmakerlabs.uk ServerAlias kit
cd ../sites-enabled
ln -s ../sites-available/001-neo 001-neo
ln -s ../sites-available/002-littlehouse 002-littlehouse
ln -s ../sites-available/003-kit 003-kit
Establish the web space
cd /var/www
sudo mkdir public_html
sudo mkdir neo
sudo mkdir kit
cd public_html
sudo vi index.html
<html><body><h1>neo.richmondmakerlabs.uk</h1> <p>This is the permanent server at Little House.</p> <p> Linux, Apache, MySQL, PHP < /p> <p> see php info < a href="phpinfo.php">here</a></p> </body></html>
sudo vi phpinfo.php
<?php phpinfo(); ?>
Reboot
sudo shutdown -r now
The web site should now be working, htttp://littlehouse.richmondmakerlabs.uk
Also littlehouse/phpmyadmin should be there
Give users sudo powers
sudo usermod -a -G sudo andres
sudo usermod -a -G sudo arthur
sudo usermod -a -G sudo ...
MySQl, django
cd
sudo apt-get install mysql-client
sudo apt-get install python-django
sudo ln -s /usr/lib/python2.7/dist-packages/django/bin/django-admin.py /usr/local/bin
sudo apt-get install libapache2-mod-wsgi
Create group dev, add developers
sudo addgroup dev
sudo adduser ianb dev
sudo adduser dan dev
Make the web spaces writeable by group dev
sudo chgrp dev kit neo public_html
sudo chmod g+w kit neo public_html