Workshop:2012/03/22

From SOWNWiki
Jump to: navigation, search
Workshop (to be) held on 2012/03/22 at 17:30
The date "{{{enddate}}} 20:00" was not understood.
in Access Grid Room

Previous workshop: 17 March 2012 11:00:00 Next workshop: 29 March 2012 17:30:00


Task List

  • Work on package management system

Outcomes

Kohana

On a Ubuntu 10.04 LTS server/desktop, you can do the following:

add-apt-repository ppa:kohana/stable
sed -i "s/`lsb_release -cs`/maverick/" /etc/apt/sources.list.d/kohana-stable-lucid.list
apt-get update
apt-get install 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

To enable php in home dirs there is a section in /etc/apache2/mods-available/php5.conf which disables it by default now.

Install your application in ~/public_html/application and ensure that the logs and cache directory are writable by the web-server.

cp /usr/share/php/kohana3.2/index.php ~/public_html
vi ~/public_html/index.php

Locate the define line for APPPATH and change it to ~/public_html/application (where the ~ is fully resolved. You should leave the DIRECTORY_SEPARATOR bit in place) (more info @ http://forum.kohanaframework.org/discussion/comment/62537) The variables set at the top are NOT used (kohana3.2 2012/03/22).

At this point you need to check you have all the modules you need for your bootstrap to work. A useful way of debugging is to edit application/bootstrap.php and add the following on the end of it (before the close php tag):

echo('bootstrap succeeded');
exit();

This way you can test the bootstrap loads ok. All other issues will be with the application itself. Remember to remove this code after you are done (e.g. it loads for you in the browser).

Now to enable the /package/ URL rewriting...

create a directory in your public_html called package

In this directory add the following .htaccess file, change 'username' to your username!

# Accept client certs for this directory. If you want to identify them by SSL.
# SSLVerifyClient optional_no_ca

# Chuck all urls at kohana.
RewriteEngine on
RewriteBase /package/
RewriteRule .* /~username/index.php/package/$0 [PT]

In a browser go to /~username/package/config/backfire/sown_openwrt_core/1/credentials and it should moan that Doctrine isn't found (2012-03-22)


Misc

  • Fixed auth2 proxying external requests back to itself, repeatedly.
    • The following was added to proxy.conf
# Don't proxy traffic you don't want to localhost ... because it will proxy in
# a loop until the first request times out.
home_server nowhere {
        type = auth+acct
        ipaddr = 127.0.0.1
        port = 18
        secret = this_server_doesnt_exist
        response_window = 20
        zombie_period = 1
        revive_interval = 120
        status_check = status-server
        check_interval = 30
        num_answers_to_alive = 3
}
    • This server was then added to the peering's home_server_pool.
    • This bizarre hack was done to avoid removing config 'live' from the dev radius-server, it is merely commented out.
  • Added a page describing sowns 'holes' in the ECS Firewall
    • Changes have been requested via jitterbug
Facts about "2012/03/22"
Has date22 March 2012 17:30:00 +
Has location32/3073 +