Welcome

PDF Print E-mail

Compaq ML350In the second part of this tutorial series, we're going to install Trac and integrate it with the Subversion repository we setup last time, and also add Basic Authentication.


We're mostly going to be following the TracUbuntuMultipleProjects tutorial from the Trac wiki.  A lot of this tutorial is based (ie copied!) from that post.  Some others were mixed in there for good measure, I've tried to list those I could at the end of the article.


Install Trac from the repositories - a whole bunch of other dependencies will be added too, mostly related to python and graphiz.

sudo apt-get install php5-cli python-setuptools libapache2-mod-python libapache2-svn python-pygments graphiz trac

Create the directory where all the Trac projects will live.
sudo mkdir /var/trac
sudo chown www-data:www-data /var/trac

We'll be putting Trac on our default web site, you may want to use a different Virtual Host.
sudo vim /etc/apache2/sites-enabled/000-default

Just before the </VirtualHost> add:
    <Location /projects> #set up Trac
        SetHandler mod_python
        PythonHandler trac.web.modpython_frontend
        PythonOption TracEnvParentDir /var/trac
        PythonOption TracUriRoot /projects
    </Location>

You've got the Subversion repository setup already right?  If not, check out Part One.


Set the correct permissions for the Trac pages, and restart Apache to make everything so far take effect.

sudo chown -R www-data /usr/share/trac
sudo apache2ctl graceful

Create a test project in Trac.  Accept all the defaults, apart from when it asks for the Subversion path, put /var/svn/myproject.
sudo trac-admin /var/trac/myproject initenv

That should end with a "Congratulations!" message. If not, well, oops.


Make sure all the files are web-accessible

sudo chown -R www-data:www-data /var/trac/myproject

And try it out (I had to restart Apache one more time, not sure why)


Go to http://yourmachine/projects to see Trac it working.

Authentication


Now we're going to add Basic Authentication to Trac.  This just uses Apache HTTP auth.


First add an admin account to the project

sudo htpasswd -c /var/trac/myproject/.htpasswd admin

Edit your Apache site configuration to allow AuthConfig statements
sudo vim /etc/apache2/sites-enabled/000-default

Add this at the top of the file
<Directory /var/www/>
        AllowOverride AuthConfig
</Directory>

Add this just before the </VirtualHost>
    <Location /projects/myproject>
        AuthType Basic
        AuthName "My Project"
        AuthUserFile /var/trac/myproject/.htpasswd
        Require valid-user
    </Location>

And that should be it.  Just one last restart and you can now visit your Projects site again, and this time be prompted for authentication.
sudo apache2ctl graceful

Upgrade to latest Trac


The version of Trac shipped in the Ubuntu repositories (at the time I'm writing this) is 0.10.4 - so you might want to upgrade to the latest version (0.11)


Install the new version of Trac

sudo easy_install Trac
sudo trac-admin /var/trac/projects upgrade
sudo trac-admin /var/trac/projects wiki upgrade

The new version needs Python Eggs
sudo mkdir /var/www/.python-eggs
sudo chown www-data:www-data /var/www/.python-eggs

Let admin (change to whoever you like) admin the project
sudo trac-admin /var/trac/myproject permission add admin TRAC_ADMIN

Restart and test!
sudo apache2ctl graceful

Additions


Finally, we can install some additional Trac modules to make things work better
sudo easy_install http://svn.edgewall.org/repos/genshi/trunk/
sudo easy_install http://trac-hacks.org/svn/accountmanagerplugin/trunk
sudo easy_install http://trac-hacks.org/svn/customfieldadminplugin/0.11
sudo easy_install http://trac-hacks.org/svn/eclipsetracplugin/tracrpcext/0.10
sudo easy_install http://trac-hacks.org/svn/iniadminplugin/0.11
sudo easy_install http://trac-hacks.org/svn/masterticketsplugin/0.11
sudo easy_install http://trac-hacks.org/svn/pagetopdfplugin/0.10/
sudo easy_install http://trac-hacks.org/svn/progressmetermacro/0.11
sudo easy_install http://trac-hacks.org/svn/ticketdeleteplugin/0.11
sudo easy_install http://trac-hacks.org/svn/tracwysiwygplugin/0.11
sudo easy_install http://wikinotification.ufsoft.org/svn/trunk

I needed to persuade Trac that some odd "CTP" files were actually PHP files. To do this, just add the custom extension to the relevant MIME type
sudo vim /etc/mime.types

So it says something like
application/x-httpd-php   phtml pht php ctp

Using LDAP


sudo vim /etc/apache2/sites-enabled/000-default


Should now have the following <Location> section


<Location /svn>
DAV svn
SVNParentPath /var/svn
AuthType Basic
AuthBasicProvider ldap
AuthName "Subversion Repository"
</Location>

References


Last Updated on Wednesday, 16 July 2008 19:23
 
PDF Print E-mail

Compaq ML350


In this tutorial-series we're going to create a Subversion and Trac server for integrated Project and Source Code Management.


Start with My default Ubuntu build for testing, development and tutorials.


Install Subversion and the extra tools

sudo apt-get install subversion subversion-tools

This will also install (if you don't have them already) the packages libneon27, libsvn1 and subversion.


Set up a new security group for the subversion server

sudo groupadd subversion

Add the Apache user, and optionally yourself, to the new group
sudo adduser www-data subversion
sudo adduser mark subversion

Create an initial repository and set up the correct security
sudo mkdir /var/svn
cd /var/svn
sudo mkdir myproject
sudo chown -R www-data:subversion myproject
sudo chmod -R g+rws myproject
sudo svnadmin create /var/svn/myproject
sudo chmod -R g+rws myproject

(That last chmod is needed to reset the permissions on folders created by svnadmin)

Server Configuration


Setup the Subversion server process to allow authorisation
sudo vim myproject/conf/svnserve.conf

Make this file contain just the following
[general]
password-db = passwd

Add a user to the passwd file
sudo vim myproject/conf/passwd

So it looks like
[users]
username = password

Testing


You can now test it by running the server
svnserve -d --foreground -r /var/svn

And connecting to it from another session
svn co svn://servername/myproject myproject --username username

Test it with local SSH access.  It should ask if you really want to connect to the server with the fingerprint shown, just type "yes" and press enter.  You'll then have to enter your password twice.
svn co svn+ssh://servername/var/svn/myproject myprojectssh --username username

You now have a working Subversion server!

References


Last Updated on Tuesday, 29 July 2008 17:37
 
PDF Print E-mail

DwarfI was out in town on Saturday and remembered an idea I had about using a cheap picture-frame as a ready-made component in a miniature display-base.  Unfortunately I didn't remember this until after I'd gone past all the charity and "everything for a pound" type shops, but did find a "wine bottle stand" in Asda (while picking up essential beery supplies)


This is the first part in my journey into turning a £2 bottle-coaster into a priceless display stand for a miniature...


Part 1 - A Solid Foundation







































20080127-00111 This is the thing I found in Asda - it's aparently a "wine bottle coaster" - something I'm sure everybody needs.  For a mere £2 though, I thought I could use this for something a bit more exciting.Essentially it's just a turned, slightly tapered wooden (pine?) block with a cork insert.
20080127-00112 First of all, put in a thin slice of blue polystyrene (HDPE) so that you don't end up using an entire box of Milliput in for one thing. This was made a lot easier with the use of a funky beam compass, because it lets you cut a nice neat circle.As it happens though, this piece won't be visible at all, so it doesn't really matter.I didn't glue this, because the fit was really tight, but you can if you want to.  (Use UH Porous adhesive)(For some clues on how to take the commonly 1-inch thick HDPE and make it thinner, see my Thinning Polystyrene post)
20080127-00113 The next job is to make another circle of HDPE the same as before, but tapered the edges with a craft-knife, and then sanded down with some little files.Mix up a batch of Milliput, and using some nice sculpting tools cover the dome with it.  Keep the tools damp by dipping them in a jar of water to help keep the Milliput off the tools, and also make for a nice smooth finish.
20080127-00114 This is the finished top.It doesn't matter too much if it has some little bubbles as the whole thing is going to be surfaced with various basing materials to make it look like The Great Outdoors.Leave this to cure until it's completely hard. (About 2-3 hours should do it, but 6 is better)
20080127-00115 I forgot something. (And it's optional, which is why I didn't re-jig the article to hide the fact)I like to magnetise my figures so that they stick to the bases better, it makes them easier to transport, and when people pick up the stands to have a look, the figures don't fall behind the cabinet.
20080127-00116 Luckily, the Milliput had set pretty hard, and was at least 1mm thick (mostly) all over.Cut some lines into the HDPE, and use one of the sculpting picks to genltly lever our each of the squares.
20080127-00117 Eventually you should end up with just the Milliput in the centre section, and a rough circle of HDPE around the edge.
20080127-00118 To give the magnetised bases something to stick to, find some thin ferrous metal (stuff that magnets stick to) and cut it into a shape that will fit into the underside of the dome.An old biscuit-tin works great, but be careful cutting it up, the edges are sharp.Normal (strong) scissors should do the trick, but some tin-snips are ideal.I used Evo-Stik Impact Adhesive to stick the metal to the Milliput, because it's crazily strong.  Be careful though, this stuff is a very potent solvent-based glue, so will make your head feel funny if you peer too closely at it.  Oh, and it will completely melt HDPE into a sticky mess, so don't get it all over anything.
20080127-00119 Next, cover the metal with another little sheet of HDPE.For this use a non-solvent adhesive, unless you want to end up with a molten heap, such as Uhu Porous.

Tools And Equipment Used


This is a selection of the items I used to make this stand.  I haven't listed everything because life's too short as it is, and it's healthy for you to discover some things for yourself ;)


  • A beam compass



  • UHU Porous adhesive



  • Evo-Stick Multipurpose Impact Instant Contact Adhesive



  • A biscuit tin



  • Some sculpting tools



  • High-density polystyrene (HDPE)



  • An eye of a newt



  • A knife



  • Milliput two-part epoxy



Beam CompassEvo-StikMilliputUHU

Last Updated on Monday, 28 January 2008 02:59
 
PDF Print E-mail

Compaq ML350Just a quickie this time, how to install the VMWare Tools for Ubuntu.


It should work out-of-the-box, but there's a problem with the vmhgfs module not building correctly. If you're struggling installing these tools, read on...

Prerequisites


I'm basing all this on My default Ubuntu build for testing, development and tutorials.

Preparation


Things have changed a bit, the old methods of editing the vmhgfs modules don't work anymore, so just install these Open tools until the real ones work...

Installation


Download the Open VM Tools from Launchpad.net
wget http://launchpadlibrarian.net/11947455/open-vm-tools_2008.01.23-74039-0ubuntu1_i386.deb

Install them
dpkg -i open-vm-tools_2008.01.23-74039-0ubuntu1_i386.deb

Ignore the two FATAL errors.


Done.  Let's hope they make the normal packages work some time soon.

Last Updated on Monday, 14 July 2008 18:33
 
PDF Print E-mail


DwarfYes, it was inevitable.  I couldn't resist improving my photo-rig again.  The problem with the previous setup was that it just wasn't realistically repeatable.


The miniatures were not very scientifically placed, there was just a circular hole in the backing, and a pencil notch to line up.  Of course the pencil mark gets worn off the base when you're painting it!


Also, it was impossible to keep the camera in exactly the same place, as even turning it on and off would move it enough to make time-lapse type effects impossible to pull off.


All this led to the MK-III!


The Repeatable Photograph Rig



Details


I remembered that in the shed I still had the big box of Lego from when I was into that stuff (not that I've ever really stopped) and I thought that seeing as how Lego is about the most precisely-engineered stuff people can get their hands on, it would be perfect, and boy, was it.


As you can see from the pictures, everything is now locked into position.



  • The camera is on a base with the three tripod legs in receptacles. 



  • The figure platform is kept at the desired distance from the camera, and yet can be adjusted if needed.



  • The backing, which is fairly soft foam and prone to damage, can be swapped out easily.  I also have different colours of course. (Figure 1)



  • The elevation of the camera can be reset if moved because of the various marker-points which line up with the markings in the camera's viewfinder (Figure 2)



  • One key element is the small 2x2 Lego brick glued to the bottom of the miniature bases.  This means they're always in the same place infront of the camera.



  • I need to get out more














Closeup
(Figure 1)


Camera simulation
(Figure 2) 


Targeting Closeup
(Figure 3)



The Repeatable Photograph Rig
(Figure 4)



Last Updated on Sunday, 20 January 2008 16:08
 
<< Start < Prev 1 2 3 4 5 6 7 8 9 10 Next > End >>

Page 6 of 11