Workshop:2012/04/28

From SOWNWiki
Jump to: navigation, search
Workshop (to be) held on 2012/04/28 at 11:00
The date "{{{enddate}}} 17:00" was not understood.
in Zepler CLS Lecture Room

Previous workshop: 19 April 2012 17:30:00 Next workshop: 12 May 2012 11:00:00


Note that we will possibly move to 32/3073 once power is restored to Building 32

Task List

  • More work on auth2.

Minutes

An army of VMs were installed on morse laptop. The following instructions produce a 'working' machine/build to the current state of working.

sudo add-apt-repository ppa:kohana/stable
sudo sed -i "s/`lsb_release -cs`/maverick/" /etc/apt/sources.list.d/kohana-stable-lucid.list

sudo apt-get update
sudo apt-get install git-core libkohana3.2-core-php libkohana3.2-mod-auth-php libkohana3.2-mod-cache-php libkohana3.2-mod-codebench-php libkohana3.2-mod-database-php libkohana3.2-mod-image-php libkohana3.2-mod-orm-php libkohana3.2-mod-unittest-php mysql-client mysql-server php5-mysql libmysqlclient15-dev


sudo a2enmod mod_rewrite
sudo /etc/init.d/apache2 restart
sudo /etc/init.d/mysql restart

sudo mkdir -p /srv/www/default/application
sudo cp /usr/share/php/kohana3.2/index.php /srv/www/default

cd /srv/www/default

# Hack httpd to use /srv/ww/default
# Hack httpd.conf to allow allow override any

sudo git clone git://github.com/sown/node_control.git .

cd /srv/www
sudo git clone https://github.com/Flynsarmy/KODoctrine2.git
sudo ln -s /srv/www/KODoctrine2/modules/doctrine2/ /usr/share/php/kohana3.2/modules/doctrine2

cd /tmp
wget http://www.doctrine-project.org/downloads/DoctrineORM-2.2.2-full.tar.gz
tar -zxf DoctrineORM-2.2.2-full.tar.gz
sudo mv DoctrineORM-2.2.2/* /usr/share/php/kohana3.2/modules/doctrine2/classes/vendor/doctrine
rm DoctrineORM-2.2.2-full.tar.gz
rm -r DoctrineORM-2.2.2

echo "CREATE DATABASE sown_data; GRANT ALL PRIVILEGES ON sown_data.* TO 'sown'@'localhost' IDENTIFIED BY 'password'" | mysql -u root
mysql -u sown --password=password sown_data < /srv/www/default/sql/sown_data.sql

sudo chmod 2777 /srv/www/default/application/logs
sudo chmod 2777 /srv/www/default/application/cache
sudo chmod 2777 -R /srv/www/default/application/models/proxies

sudo chown -R root:www-data /srv/www/default/application


Accessing: http://192.168.122.251/package/config/backfire/sown_openwrt_core/1/credentials Should display:

Node: [Model_Node id:1 name:node900]object(ReflectionClass)#104 (1) { ["name"]=> string(10) "Model_Node" } array(5) { [0]=> &object(ReflectionProperty)#103 (2) { ["name"]=> string(9) "boxNumber" ["class"]=> string(10) "Model_Node" } [1]=> &object(ReflectionProperty)#147 (2) { ["name"]=> string(13) "firmwareImage" ["class"]=> string(10) "Model_Node" } [2]=> &object(ReflectionProperty)#146 (2) { ["name"]=> string(5) "notes" ["class"]=> string(10) "Model_Node" } [3]=> &object(ReflectionProperty)#145 (2) { ["name"]=> string(11) "certificate" ["class"]=> string(10) "Model_Node" } [4]=> &object(ReflectionProperty)#150 (2) { ["name"]=> string(11) "vpnEndpoint" ["class"]=> string(10) "Model_Node" } } filemtime(): stat failed for /srv/www/auth/config/authorized_keys


vpn was fixed: http://www.sown.org.uk/wiki/Developers:Sown-vpn_resurrection

Facts about "2012/04/28"
Has date28 April 2012 11:00:00 +
Has location59/1257 +