Archive for June, 2009
Install Eclipse Galileo for Django and Pinax – Part 2
Now, onto getting Pinax installed for development purposes:
I really don’t like how things have gone with Pinax installation in the past few months. I’m going to give my own take on things. Pinax has moved to GitHub and so should you.
First, create an account at GitHub. Then, fork Pinax so you have your own copy to work with. For me, I have my development version here. If you want this repository to be private, you can pay GitHub $7/month – well worth it if this is a corporate gig.
Now you can follow the Pinax directions from your own fork.
$ curl -O http://github.com/AdamN/pinax/raw/master/scripts/pinax-boot.py
$ python pinax-boot.py --development ../Documents/workspace/WhateverYouNamedProject/src/pinax
$ source ../Documents/workspace/WhateverYouNamedProject/src/pinax/bin/activate
(pinax)$ cd ../Documents/workspace/WhateverYouNamedProject/src/pinax
(pinax)$ pip install --requirement src/pinax/requirements/external_apps.txt
At this point, if you have an existing installation of Pinax on your machine, you may get an error about django-wikiapp being the wrong version. In a new command line tab, run:
pip install django-wikiapp==0.1.2
If it says it’s already installed, you may need to delete the existing django-wikiapp in the directory shown by the error in the pip install command above. Now it’s time to start a project:
(pinax)$ pinax-admin clone_project basic_project myproject
You now have a Pinax site in myproject/ directory
(pinax)$ cd myproject
(pinax)$ ./manage.py syncdb
(pinax)$ ./manage.py runserver
Now, go to your browser and navigate to http://127.0.0.1:8000
Hopefully, you now see a Pinax website in all its glory.
Install Eclipse Galileo for Django and Pinax – Part 1
Today I decided to see if I could do a proof of concept Django/Pinax deployment for an anti-fraud advertising service. Since they already use PHP for their legacy codebase and since the existing developer uses Eclipse and the Zend Plugin for debugging, I decided to use Eclipse for the proof of concept (since I have to convince that person to switch to Django).
First things first. Update your Mac to the latest and greatest software and JVM. A new JVM literally came out today so that’s what I did.
Now, go download the bleeding edge release candidate Eclipse for Java EE Cocoa Version – Galileo. Some people will probably want something else, but I say that Cocoa apps are way nicer than Carbon ones and anyway, I went with Galileo. The Java EE version has web development tools built in there which I thought would be important. Feel free to comment below with a leaner way to do this – I’m not using Java.
Now, grab the new version of Subversion (if you’re using Subversion). I got, and highly recommend, version 1.6.2. I usually don’t get the latest SVN packages but when trying 1.4.x it did not work.
Spin up Eclipse and grab some plugins. You’ll need the PyDev and Subclipse plugins. Go to Help > Install New Software, and install these:
Get the 1.6 series of Subclipse here:
http://subclipse.tigris.org/update_1.6.x
PyDev for debugging and highlighting:
http://pydev.sourceforge.net/updates/
For Subclipse, you’ll get alot of options. Just install everything (again, I’m usually lean but I tried not installing everything and had issues – I would just do it all).
Now, run through the fantastic Getting Started guide on the PyDev website. It’s written for Windows and a previous version, but you should be able to get through everything.
When you’ve gone through that, it’s time to get your existing SVN project into the project you created for PyDev above. Just right-click on the project and select ‘Import’. From there, choose SVN and import from your svn repository (if you have one – otherwise, skip this).
I will get to Pinax on the next post, when I figure it out
Amazon Web Services
Whew, it’s been a long time since a post. Here’s a small presentation about Amazon Web Services:
You are currently browsing the Varud blog archives for June, 2009.