Please login to participate.
Wiki Page

QuickStart Buildout

.

Cyn.in Dependency installation using Package Managers

Ubuntu 8.0.4 (Hardy)

sudo apt-get build-dep python-ldap python-lxml

sudo apt-get install build-essential gcc g++ libc6-dev libssl-dev zlib1g-dev libjpeg62-dev libreadline5-dev readline-common wv python2.4-dev poppler-utils python-imaging python-libxml2 libxml2-dev libxslt1-dev subversion libdb4.4-dev libldap2-dev libsasl2-dev libssl-dev python-ldap python-setuptools

Ubuntu 8.1.0 (Intrepid) and Debian 5.0 (Lenny)

sudo apt-get install build-essential gcc g++ libc6-dev libssl-dev zlib1g-dev libjpeg62-dev libreadline5-dev readline-common wv python2.4-dev poppler-utils python-imaging python-libxml2 libxml2-dev libxslt1-dev subversion libsasl2-dev libssl-dev python-ldap libdb-dev libldap2-dev python-setuptools

Ubuntu 9.04 (Jaunty)

sudo apt-get install build-essential libssl-dev libjpeg62-dev libreadline5-dev wv  libxml2-dev libxslt1-dev libsasl2-dev poppler-utils libdb4.4-dev libldap2-dev python2.4-dev

Ubuntu 9.10 (Karmic)

sudo apt-get install build-essential libssl-dev libjpeg62-dev libreadline5-dev wv  libxml2-dev libxslt1-dev libsasl2-dev poppler-utils libdb-dev libldap2-dev python2.4-dev

Make a new virtualenv for your login

After getting dependencies using your package manager, checkout any cyninsrc branch/trunk. From this, you'll find a file, ez_setup.py, you have to run this to install easy_install:

sudo python2.4 ez_setup.py

Next, we install virtualenv which will be used for installing required python dependencies of cyn.in:

sudo easy_install-2.4 virtualenv

Lets start by making a virtualenv based virtual python environment for our own usermode python installation:

virtualenv --python=python2.4 -v --no-site-packages ~/venv

This makes a local python install at ~venv which we will now use to do the buildout. First we need to easy_install the dependencies.

Install python dependencies to your VirtualEnv

Use this concatenated command that will easy_install all dependencies together.

~/venv/bin/easy_install-2.4 ZopeSkel && ~/venv/bin/easy_install-2.4 lxml && ~/venv/bin/easy_install-2.4 python-ldap && ~/venv/bin/easy_install-2.4 -i http://dist.serverzen.com/pypi/simple PILwoTk

Do Bootstrap

That's it for the dependencies, you're ready to do the buildout, just take care to use the venv python2.4 instead of the system-wide one.

cd to your buildout directory (it must have bootstrap.py, buildout.cfg, versions.cfg and user.cfg in it) and:

~/venv/bin/python2.4 bootstrap.py

Do Buildout

Now you can proceed as normal by running your buildout as always:

./bin/buildout -c user.cfg

Description
Quick Steps required to be done to get a fully working Cyn.in buildout development environment
Comments (9)
athospat Nov 19, 2009 08:09 PM
Hi,
cool, I have installed Cyn.in from source code on a Jaunty based virtual machine. Just a minor comment to the QuickStart Buildout: the README.txt file in the cyn305 sources folder is almost identical to the QuickStart Buildout but it is more complete: the step about setting the effective-user is not mentioned in the QuickStart.
Congrats for the excellent quality, even a newbie can get through the installation.
dhiraj Nov 19, 2009 08:24 PM
Hmmm... cool, so buildout from source is working easily now. :)

Will be working on elaborating on the developer side of the picture a little in a few days. In 3.0.4 the Readme.txt file had slipped out of the spec, so we redid the Readme based on the new way using virtualenv, and you're right, it's essentially a re-formatted paste of the quickstart part in the readme, which retains the rest of the valid parts of the original text. The rest of the topics in the whole dev environment setup on the Cyn.in Developers wiki haven't gotten started yet, they'll hopefully be fleshed out soon.
dhiraj Nov 23, 2009 01:08 PM
Added new dependency list for Ubuntu 9.10 (Karmic). There's only 1 minor change in dependency list, karmic does not have libdb4.4-dev, instead just ibdb-dev should do. This dependency is primarily for LDAP support, so while this shouldn't cause a problem, as such, do please tell us if this causes issues in setting up LDAP integration with Cyn.in buildout running on Karmic.
deadlines Feb 04, 2010 05:11 PM
These instructions need an overhaul, multiple problems noted and additional newer scripts are being installed (e.g. easy_install2.5) that this guide makes no mention of. After attempting a run through and realizing the rules break down at the Do Bootstrap phase, I tried to scrap everything and start from scratch. Unfortunately now all I get when I attempt to run the easy_install2.4 or easy_install2.5 is:

Processing virtualenv
error: Not a recognized archive type: virtualenv

So, two questions:

1.) Why aren't the bootstrap.py and buildout.cfg files being placed in ~/venv/bin? Are you supposed to copy them manually from the root? Trying that workaround was fruitless, you end up receiving errors when you attempt to build.

2.) What's the deal with the easy_install2.5 script? Are we supposed to be using this? If not, why is it even included?

Any help would be appreciated.


deadlines Feb 04, 2010 05:21 PM
Ok, my mistake I just noticed the easy_install step already installed virtualenv hence the, "not a recognized archive type" error.

The only problem in the instructions lies in the ambiguity of the Do Bootstrap phase.

Here's what needs to be added, imho:

Manually copy over THREE files from your svn checkout root to your ~/venv directory: bootstrap.py, buildout.cfg AND versions.cfg

Then the bootstrap will complete properly.

dhiraj Feb 04, 2010 06:36 PM
Hi deadlines,

I'm not sure I follow your point. How come your buildout directory *did not* have these files? In the buildout source snapshot, (as well as the svn checkout) these files are there at the buildout root, right?

bootstrap.py is there in the root of the buildout. To bootstrap you have to cd to the folder that is present and run it with the virtualenv that you just created in your linux home folder.

So suppose you extracted the buildout at "/home/dhiraj/buildout" you would "cd /home/dhiraj/buildout" or just "cd ~/buildout" and then run "~/venv/bin/python2.4 bootstrap.py".
deadlines Feb 04, 2010 06:56 PM
Dhiraj,

First, thanks very much for the quick reply. Second, I screwed up big time and posted too quickly... I'll blame it on the lack of coffee. Btw, any plans to add edit/deletion of comments soon? ;) Thanks again, everything is working fine now.
dhiraj Feb 04, 2010 07:08 PM
Ah yes. Coffee. Elixir of the Geeks. I know exactly what you mean. ;)

Edit and delete of comments: Hmm... let's start a new discussion for this: http://www.cynapse.com/comm[…]sily-editable-and-deletable
jocirilo Feb 15, 2010 05:48 PM
Mais um comentário fora do assunto para apagar.
 
Loading