Re: Recommended dev environment for a Django project deployed to Linode

2013-09-16 Thread Jorge Arevalo

On Monday, September 16, 2013 7:33:49 PM UTC+2, Jorge Arevalo wrote:
>
> Hello,
>
> I'm going to start a project based on (Geo)Django + PostgreSQL/PostGIS + 
> OpenLayers/LeafLet + Bootstrap/Foundation. The project will be deployed to 
> a Linode box. That box will be created with something like this: 
> https://manager.linode.com/linodes/deploy/linode393074?StackScriptID=6482
>
> My work box is a MacBook with Mac OS X 10.6.8. There will be 2 people 
> working on the web app (me and another guy). I have almost total freedom to 
> choose, so I want to choose wisely. The whole point is that these 
> constraints should be satisfied:
>
> - I need a reliable way to upload the application to the test/production 
> environments. At least the production environment will be a Linode box. I 
> just don't want to upload files via FTP, or manually copy them with rsync, 
> or any other practice easily subject to errors. How do the professional 
> django developers set up their environment in order to deploy the app?
>
> - I'm not sure about which IDE/editor choose. I don't want to start an 
> editor war, and I've used several options in the past. My main interest is: 
> I want to focus on develop. If Eclipse/Aptana/Eric/PyCharm/any IDE can be 
> easily "linked" to my environment, that's my choice. For example, if I can 
> deploy my app to test/production environment with a couple of clicks or 
> commands, thanks to a plugin or script, that's great. Like deploying to 
> Heroku or EC2, but with Linode. Is there any IDE specially friendly with 
> this kind of development environment?
>
> - The other(s) developer(s) must be up&running ASAP. They can't spend half 
> a day installing and configuring stuff to start being productive. I guess a 
> VirtualBox machine + Vagrant would be a good choice here. But, would it 
> make more difficult the deployment cycle? And using a virtual machine to 
> just open the IDE and develop sounds like a resource waste to me. Is there 
> any other solution?
>
> I think I should use, at least, VirtualEnv, VirtualEnvWrapper and PIP, 
> like I've read in these useful links
>
>
> http://www.slideshare.net/ryan_blunden/virtualenv-and-pip-isolated-python-environments
> http://www.slideshare.net/ajdiaz/isolated-development-in-python
>
> But I'd like to know the opinion of Djanjo experts / hard "pythonistas". 
> Any suggestion is strongly appreciated.
>
> Many thanks in advance, and best regards
>
>
Sorry, the first link (from linode) requires login. It was a link to the 
description of a StakScript that does this in a Linode box: 

"A Linode.com StackScript shell script that configures a complete web 
environment with Apache, PostgreSQL/MySQL/MongoDB, Python, mod_wsgi, 
virtualenv and Django.

Optionally creates a PostgreSQL/MySQL user and database and installs 
MongoDB NoSQL database.

By default, it creates a VirtualHost using the reverse DNS of your Linode's 
primary IP and sets up a sample Django project in the /srv directory.

Installs common system and dev utilities, sets up postfix loopback, 
Uncomplicated Firewall and Fail2Ban.

Writes command output to /root/stackscript.log and records /etc changes 
using etckeeper and git. When completed notifies via email.

This StackScript is a mashup of nigma's excellent system setup StackScripts 
(https://github.com/nigma/StackScripts) and a92bz53/steakknife's etckeeper 
StackScript (https://gist.github.com/steakknife/3452111)."
 

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-09-17 Thread Vernon D. Cole

I installed a client for my favourite distributed version control system on 
my Linode instance.  I have a private repository on a public IP.  (github, 
bitbucket, or launchpad will work, depending on your dvcs of choice -- I 
have used all three, and other times I have used a private dvcs host, 
including my Linode server itself.) I "cloned" a "checkout" of my django 
system to the Linode. When I am happy from testing a new version of my 
application:  I push it to the repository,  log in to my Linode using ssh, 
and do a pull.  Easy and error free.  (My django environment is almost 
exactly like yours with PostGIS, etc.)
--

On Monday, September 16, 2013 6:33:49 PM UTC+1, Jorge Arevalo wrote:
>
> Hello,
>
> I'm going to start a project based on (Geo)Django + PostgreSQL/PostGIS + 
> OpenLayers/LeafLet + Bootstrap/Foundation. The project will be deployed to 
> a Linode box. That box will be created with something like this: 
> https://manager.linode.com/linodes/deploy/linode393074?StackScriptID=6482
>
> My work box is a MacBook with Mac OS X 10.6.8. There will be 2 people 
> working on the web app (me and another guy). I have almost total freedom to 
> choose, so I want to choose wisely. The whole point is that these 
> constraints should be satisfied:
>
> - I need a reliable way to upload the application to the test/production 
> environments. At least the production environment will be a Linode box. I 
> just don't want to upload files via FTP, or manually copy them with rsync, 
> or any other practice easily subject to errors. How do the professional 
> django developers set up their environment in order to deploy the app?
>
> - I'm not sure about which IDE/editor choose. I don't want to start an 
> editor war, and I've used several options in the past. My main interest is: 
> I want to focus on develop. If Eclipse/Aptana/Eric/PyCharm/any IDE can be 
> easily "linked" to my environment, that's my choice. For example, if I can 
> deploy my app to test/production environment with a couple of clicks or 
> commands, thanks to a plugin or script, that's great. Like deploying to 
> Heroku or EC2, but with Linode. Is there any IDE specially friendly with 
> this kind of development environment?
>
> - The other(s) developer(s) must be up&running ASAP. They can't spend half 
> a day installing and configuring stuff to start being productive. I guess a 
> VirtualBox machine + Vagrant would be a good choice here. But, would it 
> make more difficult the deployment cycle? And using a virtual machine to 
> just open the IDE and develop sounds like a resource waste to me. Is there 
> any other solution?
>
> I think I should use, at least, VirtualEnv, VirtualEnvWrapper and PIP, 
> like I've read in these useful links
>
>
> http://www.slideshare.net/ryan_blunden/virtualenv-and-pip-isolated-python-environments
> http://www.slideshare.net/ajdiaz/isolated-development-in-python
>
> But I'd like to know the opinion of Djanjo experts / hard "pythonistas". 
> Any suggestion is strongly appreciated.
>
> Many thanks in advance, and best regards
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-09-17 Thread Vernon D. Cole
Answering the other half of your question:  The choice of IDE is not nearly 
as important as its ease of integration with your dvcs.  If you are already 
familiar with a good one, don't change.

On my present project, my boss and I are both using PyCharm, and my other 
co-worker is using Eclipse, since he is more comfortable (and therefore, 
more productive) with it. Both IDE's have good integration with git (my 
least favourite dvcs, but the boss's choice) and our sharing is done using 
a group private repository on github.  This is on Ubuntu Linux, it all 
works well.   In the evening hours, I use PyCharm on Windows 7 to 
contribute to an open source project hosted on bitbucket using mercurial. 
Both projects end up being tested on the same Linode.

Yes, use virtualenv.  I also made the mistake of thinking of it as a 
virtual computer.  It is not.  It is only a method of separating Python 
library directories so that you can experiment with different 
configurations easily.  It does not slow anything down, and actually makes 
installation of packages easier.  Use virtualenvwrapper to make switching 
environments easy.  PyCharm also supports virtual environments as well as 
django projects. It is commercial, and suffers from a few Java 
idiosyncrasies, but the boss paid for the license ;-) so I don't mind.

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-09-25 Thread Jorge Arevalo
Hello,

First of all, many thanks for your response. Sorry for the delay answering 
this. I was in a business trip. 

So, you basically have 2 environments: your own machine, and the Linode 
box. You make the development and testing in your machine, and Linode is 
for production purposes. And you connect both environments via dvcs 
push/pull. Right?

I like it because it's simple and doesn't seem to be specially prone to 
errors. I'd just like to add a third scenario here, to end up with:

- Development environment: my own machine (Mac OS X) with all the software 
stack installed.
- Testing environment: my new addition. I would like to put this 
environment outside of my machine
- Production environment: the Linode box.

I can do the communication via push/pull, if there's no other way to 
"deploy" software to production with Python/Django (it's simple, I like 
it). And maybe I can have 2 urls (testing and production) in the Linode 
box. Testing just accessible to developers and testers, and production open 
to normal users. Does it make sense?

Thanks again

On Tuesday, September 17, 2013 3:50:55 PM UTC+2, Vernon D. Cole wrote:
>
>
> I installed a client for my favourite distributed version control system 
> on my Linode instance.  I have a private repository on a public IP.  
> (github, bitbucket, or launchpad will work, depending on your dvcs of 
> choice -- I have used all three, and other times I have used a private dvcs 
> host, including my Linode server itself.) I "cloned" a "checkout" of my 
> django system to the Linode. When I am happy from testing a new version of 
> my application:  I push it to the repository,  log in to my Linode using 
> ssh, and do a pull.  Easy and error free.  (My django environment is almost 
> exactly like yours with PostGIS, etc.)
> --
>
> On Monday, September 16, 2013 6:33:49 PM UTC+1, Jorge Arevalo wrote:
>>
>> Hello,
>>
>> I'm going to start a project based on (Geo)Django + PostgreSQL/PostGIS + 
>> OpenLayers/LeafLet + Bootstrap/Foundation. The project will be deployed to 
>> a Linode box. That box will be created with something like this: 
>> https://manager.linode.com/linodes/deploy/linode393074?StackScriptID=6482
>>
>> My work box is a MacBook with Mac OS X 10.6.8. There will be 2 people 
>> working on the web app (me and another guy). I have almost total freedom to 
>> choose, so I want to choose wisely. The whole point is that these 
>> constraints should be satisfied:
>>
>> - I need a reliable way to upload the application to the test/production 
>> environments. At least the production environment will be a Linode box. I 
>> just don't want to upload files via FTP, or manually copy them with rsync, 
>> or any other practice easily subject to errors. How do the professional 
>> django developers set up their environment in order to deploy the app?
>>
>> - I'm not sure about which IDE/editor choose. I don't want to start an 
>> editor war, and I've used several options in the past. My main interest is: 
>> I want to focus on develop. If Eclipse/Aptana/Eric/PyCharm/any IDE can be 
>> easily "linked" to my environment, that's my choice. For example, if I can 
>> deploy my app to test/production environment with a couple of clicks or 
>> commands, thanks to a plugin or script, that's great. Like deploying to 
>> Heroku or EC2, but with Linode. Is there any IDE specially friendly with 
>> this kind of development environment?
>>
>> - The other(s) developer(s) must be up&running ASAP. They can't spend 
>> half a day installing and configuring stuff to start being productive. I 
>> guess a VirtualBox machine + Vagrant would be a good choice here. But, 
>> would it make more difficult the deployment cycle? And using a virtual 
>> machine to just open the IDE and develop sounds like a resource waste to 
>> me. Is there any other solution?
>>
>> I think I should use, at least, VirtualEnv, VirtualEnvWrapper and PIP, 
>> like I've read in these useful links
>>
>>
>> http://www.slideshare.net/ryan_blunden/virtualenv-and-pip-isolated-python-environments
>> http://www.slideshare.net/ajdiaz/isolated-development-in-python
>>
>> But I'd like to know the opinion of Djanjo experts / hard "pythonistas". 
>> Any suggestion is strongly appreciated.
>>
>> Many thanks in advance, and best regards
>>
>>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-09-25 Thread Jorge Arevalo
Fine. I don't think my boss is going to pay for PyCharm license, so I'll 
probably go for Eclipse now (I don't really like it too much, but if works, 
it's ok for me)

About virtualenv, is there any method to provide something like a script to 
create a virtualenv, install the needed software and have a working 
environment in a few commands? Something like "vagrantfile for 
virtualenv" http://docs.vagrantup.com/v2/vagrantfile/index.html

Again, many thanks for your useful insights

On Tuesday, September 17, 2013 4:29:14 PM UTC+2, Vernon D. Cole wrote:
>
> Answering the other half of your question:  The choice of IDE is not 
> nearly as important as its ease of integration with your dvcs.  If you are 
> already familiar with a good one, don't change.
>
> On my present project, my boss and I are both using PyCharm, and my other 
> co-worker is using Eclipse, since he is more comfortable (and therefore, 
> more productive) with it. Both IDE's have good integration with git (my 
> least favourite dvcs, but the boss's choice) and our sharing is done using 
> a group private repository on github.  This is on Ubuntu Linux, it all 
> works well.   In the evening hours, I use PyCharm on Windows 7 to 
> contribute to an open source project hosted on bitbucket using mercurial. 
> Both projects end up being tested on the same Linode.
>
> Yes, use virtualenv.  I also made the mistake of thinking of it as a 
> virtual computer.  It is not.  It is only a method of separating Python 
> library directories so that you can experiment with different 
> configurations easily.  It does not slow anything down, and actually makes 
> installation of packages easier.  Use virtualenvwrapper to make switching 
> environments easy.  PyCharm also supports virtual environments as well as 
> django projects. It is commercial, and suffers from a few Java 
> idiosyncrasies, but the boss paid for the license ;-) so I don't mind.
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-09-25 Thread Bill Freeman
I guess that it's what you're used to.  I'm perfectly happy with emacs
(less so with vi or vim, but still happy enough).  I'm happy with emac's
python mode, css mode, etc.  There's even supposed to be help for Django
templates now.  I'm using the Espresso add-on for JavaScript.  It's not
everything that the IDEs offer, but I don't have to keep re-learning how to
do things.  vim has some pretty good syntax support too.  I certainly
wouldn't pay for something.  And having installed eclipse, it makes emacs
look light weight.

Indeed, I, too, tend to develop and test on my laptop, when I'm happy,
check in my chaanges (mercurial), push to the linode, ssh in, update to
head, and touch the wsgi script file (IIRC).  In a pinch I can directly
edit on the linode, using vim through ssh, or emacs tramp mode over ssh,
or, if you want to install your favorite X based editor on the linode,
through a ssh -Y tunnel.

Bill, the curmudgeon


On Wed, Sep 25, 2013 at 2:06 PM, Jorge Arevalo wrote:

> Fine. I don't think my boss is going to pay for PyCharm license, so I'll
> probably go for Eclipse now (I don't really like it too much, but if works,
> it's ok for me)
>
> About virtualenv, is there any method to provide something like a script
> to create a virtualenv, install the needed software and have a working
> environment in a few commands? Something like "vagrantfile for virtualenv"
> http://docs.vagrantup.com/v2/vagrantfile/index.html
>
> Again, many thanks for your useful insights
>
>
> On Tuesday, September 17, 2013 4:29:14 PM UTC+2, Vernon D. Cole wrote:
>>
>> Answering the other half of your question:  The choice of IDE is not
>> nearly as important as its ease of integration with your dvcs.  If you are
>> already familiar with a good one, don't change.
>>
>> On my present project, my boss and I are both using PyCharm, and my other
>> co-worker is using Eclipse, since he is more comfortable (and therefore,
>> more productive) with it. Both IDE's have good integration with git (my
>> least favourite dvcs, but the boss's choice) and our sharing is done using
>> a group private repository on github.  This is on Ubuntu Linux, it all
>> works well.   In the evening hours, I use PyCharm on Windows 7 to
>> contribute to an open source project hosted on bitbucket using mercurial.
>> Both projects end up being tested on the same Linode.
>>
>> Yes, use virtualenv.  I also made the mistake of thinking of it as a
>> virtual computer.  It is not.  It is only a method of separating Python
>> library directories so that you can experiment with different
>> configurations easily.  It does not slow anything down, and actually makes
>> installation of packages easier.  Use virtualenvwrapper to make switching
>> environments easy.  PyCharm also supports virtual environments as well as
>> django projects. It is commercial, and suffers from a few Java
>> idiosyncrasies, but the boss paid for the license ;-) so I don't mind.
>>
>>  --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-09-25 Thread Vernon D. Cole
Yes, I like to have three levels, too.  I call the middle one "staging".
You can tear it down and build it up again as many times as needed to get
it right.

A ten-year-old PC will work fine for staging practice. Blow the dust out
(the dust affects cooling and leads to poor reliability), load Ubuntu, and
park it in an unused corner somewhere.  My home-office Linux box is a Dell
desktop purchased at a University surplus sale for $20 six or seven years
ago. It runs Apache, MySQL, Asterisk, and the Python program that regulates
the lights and heat in our Iguana enclosure. The most expensive component
(other than the iguana) is a $50 UPS.  Much easier than trying to make your
production machine do double duty.

I use a structured settings module to switch back-and-forth between the
three levels.  Look at the manage.py and the formhub/settings directory in
https://github.com/vernondcole/formhub for an example how to do that.
Also look at requirements.pip in that repository for an idea how to load
most of the prerequisites automatically. Documentation is in the wiki of
https://github.com/modilabs/formhub/wiki/_pages .  (Formhub is a django
system used to receive generic survey data taken using android devices
offline.)




On Wed, Sep 25, 2013 at 12:49 PM, Bill Freeman  wrote:

> I guess that it's what you're used to.  I'm perfectly happy with emacs
> (less so with vi or vim, but still happy enough).  I'm happy with emac's
> python mode, css mode, etc.  There's even supposed to be help for Django
> templates now.  I'm using the Espresso add-on for JavaScript.  It's not
> everything that the IDEs offer, but I don't have to keep re-learning how to
> do things.  vim has some pretty good syntax support too.  I certainly
> wouldn't pay for something.  And having installed eclipse, it makes emacs
> look light weight.
>
> Indeed, I, too, tend to develop and test on my laptop, when I'm happy,
> check in my chaanges (mercurial), push to the linode, ssh in, update to
> head, and touch the wsgi script file (IIRC).  In a pinch I can directly
> edit on the linode, using vim through ssh, or emacs tramp mode over ssh,
> or, if you want to install your favorite X based editor on the linode,
> through a ssh -Y tunnel.
>
> Bill, the curmudgeon
>
>
> On Wed, Sep 25, 2013 at 2:06 PM, Jorge Arevalo 
> wrote:
>
>> Fine. I don't think my boss is going to pay for PyCharm license, so I'll
>> probably go for Eclipse now (I don't really like it too much, but if works,
>> it's ok for me)
>>
>> About virtualenv, is there any method to provide something like a script
>> to create a virtualenv, install the needed software and have a working
>> environment in a few commands? Something like "vagrantfile for virtualenv"
>> http://docs.vagrantup.com/v2/vagrantfile/index.html
>>
>> Again, many thanks for your useful insights
>>
>>
>> On Tuesday, September 17, 2013 4:29:14 PM UTC+2, Vernon D. Cole wrote:
>>>
>>> Answering the other half of your question:  The choice of IDE is not
>>> nearly as important as its ease of integration with your dvcs.  If you are
>>> already familiar with a good one, don't change.
>>>
>>> On my present project, my boss and I are both using PyCharm, and my
>>> other co-worker is using Eclipse, since he is more comfortable (and
>>> therefore, more productive) with it. Both IDE's have good integration with
>>> git (my least favourite dvcs, but the boss's choice) and our sharing is
>>> done using a group private repository on github.  This is on Ubuntu Linux,
>>> it all works well.   In the evening hours, I use PyCharm on Windows 7 to
>>> contribute to an open source project hosted on bitbucket using mercurial.
>>> Both projects end up being tested on the same Linode.
>>>
>>> Yes, use virtualenv.  I also made the mistake of thinking of it as a
>>> virtual computer.  It is not.  It is only a method of separating Python
>>> library directories so that you can experiment with different
>>> configurations easily.  It does not slow anything down, and actually makes
>>> installation of packages easier.  Use virtualenvwrapper to make switching
>>> environments easy.  PyCharm also supports virtual environments as well as
>>> django projects. It is commercial, and suffers from a few Java
>>> idiosyncrasies, but the boss paid for the license ;-) so I don't mind.
>>>
>>>  --
>> You received this message because you are subscribed to the Google Groups
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to django-users+unsubscr...@googlegroups.com.
>>
>> To post to this group, send email to django-users@googlegroups.com.
>> Visit this group at http://groups.google.com/group/django-users.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>  --
> You received this message because you are subscribed to a topic in the
> Google Groups "Django users" group.
> To unsubscribe from this topic, visit
> https://groups.google.com/d/topic/django-users/QhYZZF7mrIw/unsub

Re: Recommended dev environment for a Django project deployed to Linode

2013-09-25 Thread Roberto López López

Check virtualenvwrapper

http://virtualenvwrapper.readthedocs.org/en/latest/



On 09/25/2013 08:06 PM, Jorge Arevalo wrote:
> Fine. I don't think my boss is going to pay for PyCharm license, so
> I'll probably go for Eclipse now (I don't really like it too much, but
> if works, it's ok for me)
>
> About virtualenv, is there any method to provide something like a
> script to create a virtualenv, install the needed software and have a
> working environment in a few commands? Something like "vagrantfile for
> virtualenv" http://docs.vagrantup.com/v2/vagrantfile/index.html
>
> Again, many thanks for your useful insights
>
> On Tuesday, September 17, 2013 4:29:14 PM UTC+2, Vernon D. Cole wrote:
>
> Answering the other half of your question:  The choice of IDE is
> not nearly as important as its ease of integration with your
> dvcs.  If you are already familiar with a good one, don't change.
>
> On my present project, my boss and I are both using PyCharm, and
> my other co-worker is using Eclipse, since he is more comfortable
> (and therefore, more productive) with it. Both IDE's have good
> integration with git (my least favourite dvcs, but the boss's
> choice) and our sharing is done using a group private repository
> on github.  This is on Ubuntu Linux, it all works well.   In the
> evening hours, I use PyCharm on Windows 7 to contribute to an open
> source project hosted on bitbucket using mercurial. Both projects
> end up being tested on the same Linode.
>
> Yes, use virtualenv.  I also made the mistake of thinking of it as
> a virtual computer.  It is not.  It is only a method of separating
> Python library directories so that you can experiment with
> different configurations easily.  It does not slow anything down,
> and actually makes installation of packages easier.  Use
> virtualenvwrapper to make switching environments easy.  PyCharm
> also supports virtual environments as well as django projects. It
> is commercial, and suffers from a few Java idiosyncrasies, but the
> boss paid for the license ;-) so I don't mind.
>
> -- 
> You received this message because you are subscribed to the Google
> Groups "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> For more options, visit https://groups.google.com/groups/opt_out.


-- 

Roberto López López
System Developer
Parallab, Uni Computing
+47 55584091

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-09-25 Thread Cal Leeming [Simplicity Media Ltd]
+1 for virtualenvwrapper, don't know how I survived without this!!

Cal


On Wed, Sep 25, 2013 at 9:59 PM, Roberto López López
wrote:

>
> Check virtualenvwrapper
>
> http://virtualenvwrapper.readthedocs.org/en/latest/
>
>
>
>
> On 09/25/2013 08:06 PM, Jorge Arevalo wrote:
>
> Fine. I don't think my boss is going to pay for PyCharm license, so I'll
> probably go for Eclipse now (I don't really like it too much, but if works,
> it's ok for me)
>
>  About virtualenv, is there any method to provide something like a script
> to create a virtualenv, install the needed software and have a working
> environment in a few commands? Something like "vagrantfile for virtualenv"
> http://docs.vagrantup.com/v2/vagrantfile/index.html
>
>  Again, many thanks for your useful insights
>
> On Tuesday, September 17, 2013 4:29:14 PM UTC+2, Vernon D. Cole wrote:
>>
>>  Answering the other half of your question:  The choice of IDE is not
>> nearly as important as its ease of integration with your dvcs.  If you are
>> already familiar with a good one, don't change.
>>
>> On my present project, my boss and I are both using PyCharm, and my other
>> co-worker is using Eclipse, since he is more comfortable (and therefore,
>> more productive) with it. Both IDE's have good integration with git (my
>> least favourite dvcs, but the boss's choice) and our sharing is done using
>> a group private repository on github.  This is on Ubuntu Linux, it all
>> works well.   In the evening hours, I use PyCharm on Windows 7 to
>> contribute to an open source project hosted on bitbucket using mercurial.
>> Both projects end up being tested on the same Linode.
>>
>> Yes, use virtualenv.  I also made the mistake of thinking of it as a
>> virtual computer.  It is not.  It is only a method of separating Python
>> library directories so that you can experiment with different
>> configurations easily.  It does not slow anything down, and actually makes
>> installation of packages easier.  Use virtualenvwrapper to make switching
>> environments easy.  PyCharm also supports virtual environments as well as
>> django projects. It is commercial, and suffers from a few Java
>> idiosyncrasies, but the boss paid for the license ;-) so I don't mind.
>>
>>--
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>
> --
>
> Roberto López López
> System Developer
> Parallab, Uni Computing+47 55584091
>
>  --
> You received this message because you are subscribed to the Google Groups
> "Django users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to django-users+unsubscr...@googlegroups.com.
> To post to this group, send email to django-users@googlegroups.com.
> Visit this group at http://groups.google.com/group/django-users.
> For more options, visit https://groups.google.com/groups/opt_out.
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-09-26 Thread Christiano Anderson
I have the same stack, GeoDjango + PostGIS (and all its dependencies like
GDAL, Proj, GEOS, etc). My notebook runs Debian (also I have a Mac Book
Pro, but I prefer to work on Linux) and I use Digital Ocean to host my
projects, also running Debian boxes. Since Debian keeps an older version of
PostGIS, I have created my own .deb package of PostGIS 2.1.

IMHO VirtualEnv and VirtualEnvWrapper is the best way to keep your
environment updated with the same versions. I also keep a requirements.txt
file into the project (I use Git and Bitbucket) with the output of pip
freeze command.

best regards,


On 25 September 2013 15:01, Jorge Arevalo  wrote:

> Hello,
>
> First of all, many thanks for your response. Sorry for the delay answering
> this. I was in a business trip.
>
> So, you basically have 2 environments: your own machine, and the Linode
> box. You make the development and testing in your machine, and Linode is
> for production purposes. And you connect both environments via dvcs
> push/pull. Right?
>
> I like it because it's simple and doesn't seem to be specially prone to
> errors. I'd just like to add a third scenario here, to end up with:
>
> - Development environment: my own machine (Mac OS X) with all the software
> stack installed.
> - Testing environment: my new addition. I would like to put this
> environment outside of my machine
> - Production environment: the Linode box.
>
> I can do the communication via push/pull, if there's no other way to
> "deploy" software to production with Python/Django (it's simple, I like
> it). And maybe I can have 2 urls (testing and production) in the Linode
> box. Testing just accessible to developers and testers, and production open
> to normal users. Does it make sense?
>
> Thanks again
>
> On Tuesday, September 17, 2013 3:50:55 PM UTC+2, Vernon D. Cole wrote:
>>
>>
>> I installed a client for my favourite distributed version control system
>> on my Linode instance.  I have a private repository on a public IP.
>> (github, bitbucket, or launchpad will work, depending on your dvcs of
>> choice -- I have used all three, and other times I have used a private dvcs
>> host, including my Linode server itself.) I "cloned" a "checkout" of my
>> django system to the Linode. When I am happy from testing a new version of
>> my application:  I push it to the repository,  log in to my Linode using
>> ssh, and do a pull.  Easy and error free.  (My django environment is almost
>> exactly like yours with PostGIS, etc.)
>> --
>>
>> On Monday, September 16, 2013 6:33:49 PM UTC+1, Jorge Arevalo wrote:
>>>
>>> Hello,
>>>
>>> I'm going to start a project based on (Geo)Django + PostgreSQL/PostGIS +
>>> OpenLayers/LeafLet + Bootstrap/Foundation. The project will be deployed to
>>> a Linode box. That box will be created with something like this:
>>> https://manager.linode.**com/linodes/deploy/**
>>> linode393074?StackScriptID=**6482
>>>
>>> My work box is a MacBook with Mac OS X 10.6.8. There will be 2 people
>>> working on the web app (me and another guy). I have almost total freedom to
>>> choose, so I want to choose wisely. The whole point is that these
>>> constraints should be satisfied:
>>>
>>> - I need a reliable way to upload the application to the test/production
>>> environments. At least the production environment will be a Linode box. I
>>> just don't want to upload files via FTP, or manually copy them with rsync,
>>> or any other practice easily subject to errors. How do the professional
>>> django developers set up their environment in order to deploy the app?
>>>
>>> - I'm not sure about which IDE/editor choose. I don't want to start an
>>> editor war, and I've used several options in the past. My main interest is:
>>> I want to focus on develop. If Eclipse/Aptana/Eric/PyCharm/**any IDE
>>> can be easily "linked" to my environment, that's my choice. For example, if
>>> I can deploy my app to test/production environment with a couple of clicks
>>> or commands, thanks to a plugin or script, that's great. Like deploying to
>>> Heroku or EC2, but with Linode. Is there any IDE specially friendly with
>>> this kind of development environment?
>>>
>>> - The other(s) developer(s) must be up&running ASAP. They can't spend
>>> half a day installing and configuring stuff to start being productive. I
>>> guess a VirtualBox machine + Vagrant would be a good choice here. But,
>>> would it make more difficult the deployment cycle? And using a virtual
>>> machine to just open the IDE and develop sounds like a resource waste to
>>> me. Is there any other solution?
>>>
>>> I think I should use, at least, VirtualEnv, VirtualEnvWrapper and PIP,
>>> like I've read in these useful links
>>>
>>> http://www.slideshare.net/**ryan_blunden/virtualenv-and-**
>>> pip-isolated-python-**environments
>>> http://www.slideshare.net/**ajdiaz/isola

Re: Recommended dev environment for a Django project deployed to Linode

2013-09-26 Thread Ezequiel
On Wednesday, September 25, 2013 3:06:55 PM UTC-3, Jorge Arevalo wrote:

> Fine. I don't think my boss is going to pay for PyCharm license, so I'll 
> probably go for Eclipse now (I don't really like it too much, but if works, 
> it's ok for me)
>

PyCharm, which is my favorite IDE, has now a Free Community 
Edition: https://twitter.com/pycharm/status/382549991165673472

Best,
Ezequiel
http://flickrock.com/mikelpierre

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-10-09 Thread Jorge Arevalo
Thanks both for the suggestions! (and sorry for the delay, I was on a 
business trip). Looks like there's a lot of things to learn. I'll probably 
use a staging machine, like suggested. And now I'm between Eclipse, emacs 
and PyCharm. Time to work!

On Wednesday, September 25, 2013 9:48:26 PM UTC+2, Vernon D. Cole wrote:
>
> Yes, I like to have three levels, too.  I call the middle one "staging".  
> You can tear it down and build it up again as many times as needed to get 
> it right.
>
> A ten-year-old PC will work fine for staging practice. Blow the dust out 
> (the dust affects cooling and leads to poor reliability), load Ubuntu, and 
> park it in an unused corner somewhere.  My home-office Linux box is a Dell 
> desktop purchased at a University surplus sale for $20 six or seven years 
> ago. It runs Apache, MySQL, Asterisk, and the Python program that regulates 
> the lights and heat in our Iguana enclosure. The most expensive component 
> (other than the iguana) is a $50 UPS.  Much easier than trying to make your 
> production machine do double duty.
>
> I use a structured settings module to switch back-and-forth between the 
> three levels.  Look at the manage.py and the formhub/settings directory in 
> https://github.com/vernondcole/formhub for an example how to do that.   
> Also look at requirements.pip in that repository for an idea how to load 
> most of the prerequisites automatically. Documentation is in the wiki of 
> https://github.com/modilabs/formhub/wiki/_pages .  (Formhub is a django 
> system used to receive generic survey data taken using android devices 
> offline.)
>
>
>
>
> On Wed, Sep 25, 2013 at 12:49 PM, Bill Freeman 
> > wrote:
>
>> I guess that it's what you're used to.  I'm perfectly happy with emacs 
>> (less so with vi or vim, but still happy enough).  I'm happy with emac's 
>> python mode, css mode, etc.  There's even supposed to be help for Django 
>> templates now.  I'm using the Espresso add-on for JavaScript.  It's not 
>> everything that the IDEs offer, but I don't have to keep re-learning how to 
>> do things.  vim has some pretty good syntax support too.  I certainly 
>> wouldn't pay for something.  And having installed eclipse, it makes emacs 
>> look light weight.
>>
>> Indeed, I, too, tend to develop and test on my laptop, when I'm happy, 
>> check in my chaanges (mercurial), push to the linode, ssh in, update to 
>> head, and touch the wsgi script file (IIRC).  In a pinch I can directly 
>> edit on the linode, using vim through ssh, or emacs tramp mode over ssh, 
>> or, if you want to install your favorite X based editor on the linode, 
>> through a ssh -Y tunnel.
>>
>> Bill, the curmudgeon
>>
>>
>> On Wed, Sep 25, 2013 at 2:06 PM, Jorge Arevalo 
>> 
>> > wrote:
>>
>>> Fine. I don't think my boss is going to pay for PyCharm license, so I'll 
>>> probably go for Eclipse now (I don't really like it too much, but if works, 
>>> it's ok for me)
>>>
>>> About virtualenv, is there any method to provide something like a script 
>>> to create a virtualenv, install the needed software and have a working 
>>> environment in a few commands? Something like "vagrantfile for virtualenv" 
>>> http://docs.vagrantup.com/v2/vagrantfile/index.html
>>>
>>> Again, many thanks for your useful insights
>>>
>>>
>>> On Tuesday, September 17, 2013 4:29:14 PM UTC+2, Vernon D. Cole wrote:

 Answering the other half of your question:  The choice of IDE is not 
 nearly as important as its ease of integration with your dvcs.  If you are 
 already familiar with a good one, don't change.

 On my present project, my boss and I are both using PyCharm, and my 
 other co-worker is using Eclipse, since he is more comfortable (and 
 therefore, more productive) with it. Both IDE's have good integration with 
 git (my least favourite dvcs, but the boss's choice) and our sharing is 
 done using a group private repository on github.  This is on Ubuntu Linux, 
 it all works well.   In the evening hours, I use PyCharm on Windows 7 to 
 contribute to an open source project hosted on bitbucket using mercurial. 
 Both projects end up being tested on the same Linode.

 Yes, use virtualenv.  I also made the mistake of thinking of it as a 
 virtual computer.  It is not.  It is only a method of separating Python 
 library directories so that you can experiment with different 
 configurations easily.  It does not slow anything down, and actually makes 
 installation of packages easier.  Use virtualenvwrapper to make switching 
 environments easy.  PyCharm also supports virtual environments as well as 
 django projects. It is commercial, and suffers from a few Java 
 idiosyncrasies, but the boss paid for the license ;-) so I don't mind.

  -- 
>>> You received this message because you are subscribed to the Google 
>>> Groups "Django users" group.
>>> To unsubscribe from this group and stop receiving emails from it, send

Re: Recommended dev environment for a Django project deployed to Linode

2013-10-09 Thread Jorge Arevalo
Tested. Works great. Thanks a lot!

On Thursday, September 26, 2013 1:13:58 AM UTC+2, Cal Leeming [Simplicity 
Media Ltd] wrote:
>
> +1 for virtualenvwrapper, don't know how I survived without this!!
>
> Cal
>
>
> On Wed, Sep 25, 2013 at 9:59 PM, Roberto López López 
> 
> > wrote:
>
>>  
>> Check virtualenvwrapper
>>
>> http://virtualenvwrapper.readthedocs.org/en/latest/
>>
>>
>>
>>
>> On 09/25/2013 08:06 PM, Jorge Arevalo wrote:
>>  
>> Fine. I don't think my boss is going to pay for PyCharm license, so I'll 
>> probably go for Eclipse now (I don't really like it too much, but if works, 
>> it's ok for me) 
>>
>>  About virtualenv, is there any method to provide something like a 
>> script to create a virtualenv, install the needed software and have a 
>> working environment in a few commands? Something like "vagrantfile for 
>> virtualenv" http://docs.vagrantup.com/v2/vagrantfile/index.html
>>
>>  Again, many thanks for your useful insights
>>
>> On Tuesday, September 17, 2013 4:29:14 PM UTC+2, Vernon D. Cole wrote: 
>>>
>>>  Answering the other half of your question:  The choice of IDE is not 
>>> nearly as important as its ease of integration with your dvcs.  If you are 
>>> already familiar with a good one, don't change.
>>>
>>> On my present project, my boss and I are both using PyCharm, and my 
>>> other co-worker is using Eclipse, since he is more comfortable (and 
>>> therefore, more productive) with it. Both IDE's have good integration with 
>>> git (my least favourite dvcs, but the boss's choice) and our sharing is 
>>> done using a group private repository on github.  This is on Ubuntu Linux, 
>>> it all works well.   In the evening hours, I use PyCharm on Windows 7 to 
>>> contribute to an open source project hosted on bitbucket using mercurial. 
>>> Both projects end up being tested on the same Linode.
>>>
>>> Yes, use virtualenv.  I also made the mistake of thinking of it as a 
>>> virtual computer.  It is not.  It is only a method of separating Python 
>>> library directories so that you can experiment with different 
>>> configurations easily.  It does not slow anything down, and actually makes 
>>> installation of packages easier.  Use virtualenvwrapper to make switching 
>>> environments easy.  PyCharm also supports virtual environments as well as 
>>> django projects. It is commercial, and suffers from a few Java 
>>> idiosyncrasies, but the boss paid for the license ;-) so I don't mind.
>>>
>>>-- 
>> You received this message because you are subscribed to the Google Groups 
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to django-users...@googlegroups.com .
>> To post to this group, send email to django...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/django-users.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>>
>>
>> -- 
>>
>> Roberto López López
>> System Developer
>> Parallab, Uni Computing+47 55584091
>>
>>  -- 
>> You received this message because you are subscribed to the Google Groups 
>> "Django users" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to django-users...@googlegroups.com .
>> To post to this group, send email to django...@googlegroups.com
>> .
>> Visit this group at http://groups.google.com/group/django-users.
>> For more options, visit https://groups.google.com/groups/opt_out.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/7d351100-bf3a-48a7-8001-822c909b7cde%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Re: Recommended dev environment for a Django project deployed to Linode

2013-10-09 Thread Jorge Arevalo
Yep. VirtualEnvWrapper looks like a winner. And thanks for the suggestion 
about the requirements.txt

On Thursday, September 26, 2013 1:36:21 PM UTC+2, Dump wrote:
>
> I have the same stack, GeoDjango + PostGIS (and all its dependencies like 
> GDAL, Proj, GEOS, etc). My notebook runs Debian (also I have a Mac Book 
> Pro, but I prefer to work on Linux) and I use Digital Ocean to host my 
> projects, also running Debian boxes. Since Debian keeps an older version of 
> PostGIS, I have created my own .deb package of PostGIS 2.1. 
>
> IMHO VirtualEnv and VirtualEnvWrapper is the best way to keep your 
> environment updated with the same versions. I also keep a requirements.txt 
> file into the project (I use Git and Bitbucket) with the output of pip 
> freeze command.  
>
> best regards,
>
>
> On 25 September 2013 15:01, Jorge Arevalo 
> > wrote:
>
>> Hello,
>>
>> First of all, many thanks for your response. Sorry for the delay 
>> answering this. I was in a business trip. 
>>
>> So, you basically have 2 environments: your own machine, and the Linode 
>> box. You make the development and testing in your machine, and Linode is 
>> for production purposes. And you connect both environments via dvcs 
>> push/pull. Right?
>>
>> I like it because it's simple and doesn't seem to be specially prone to 
>> errors. I'd just like to add a third scenario here, to end up with:
>>
>> - Development environment: my own machine (Mac OS X) with all the 
>> software stack installed.
>> - Testing environment: my new addition. I would like to put this 
>> environment outside of my machine
>> - Production environment: the Linode box.
>>
>> I can do the communication via push/pull, if there's no other way to 
>> "deploy" software to production with Python/Django (it's simple, I like 
>> it). And maybe I can have 2 urls (testing and production) in the Linode 
>> box. Testing just accessible to developers and testers, and production open 
>> to normal users. Does it make sense?
>>
>> Thanks again
>>
>> On Tuesday, September 17, 2013 3:50:55 PM UTC+2, Vernon D. Cole wrote:
>>>
>>>
>>> I installed a client for my favourite distributed version control system 
>>> on my Linode instance.  I have a private repository on a public IP.  
>>> (github, bitbucket, or launchpad will work, depending on your dvcs of 
>>> choice -- I have used all three, and other times I have used a private dvcs 
>>> host, including my Linode server itself.) I "cloned" a "checkout" of my 
>>> django system to the Linode. When I am happy from testing a new version of 
>>> my application:  I push it to the repository,  log in to my Linode using 
>>> ssh, and do a pull.  Easy and error free.  (My django environment is almost 
>>> exactly like yours with PostGIS, etc.)
>>> --
>>>
>>> On Monday, September 16, 2013 6:33:49 PM UTC+1, Jorge Arevalo wrote:

 Hello,

 I'm going to start a project based on (Geo)Django + PostgreSQL/PostGIS 
 + OpenLayers/LeafLet + Bootstrap/Foundation. The project will be deployed 
 to a Linode box. That box will be created with something like this: 
 https://manager.linode.**com/linodes/deploy/**
 linode393074?StackScriptID=**6482

 My work box is a MacBook with Mac OS X 10.6.8. There will be 2 people 
 working on the web app (me and another guy). I have almost total freedom 
 to 
 choose, so I want to choose wisely. The whole point is that these 
 constraints should be satisfied:

 - I need a reliable way to upload the application to the 
 test/production environments. At least the production environment will be 
 a 
 Linode box. I just don't want to upload files via FTP, or manually copy 
 them with rsync, or any other practice easily subject to errors. How do 
 the 
 professional django developers set up their environment in order to deploy 
 the app?

 - I'm not sure about which IDE/editor choose. I don't want to start an 
 editor war, and I've used several options in the past. My main interest 
 is: 
 I want to focus on develop. If Eclipse/Aptana/Eric/PyCharm/**any IDE 
 can be easily "linked" to my environment, that's my choice. For example, 
 if 
 I can deploy my app to test/production environment with a couple of clicks 
 or commands, thanks to a plugin or script, that's great. Like deploying to 
 Heroku or EC2, but with Linode. Is there any IDE specially friendly with 
 this kind of development environment?

 - The other(s) developer(s) must be up&running ASAP. They can't spend 
 half a day installing and configuring stuff to start being productive. I 
 guess a VirtualBox machine + Vagrant would be a good choice here. But, 
 would it make more difficult the deployment cycle? And using a virtual 
 machine to just open the IDE and develop sounds like a resource waste to 
 me. Is there any other solu

Re: Recommended dev environment for a Django project deployed to Linode

2013-10-09 Thread Jorge Arevalo
Interesting! I'm downloading it. Many thanks!

On Thursday, September 26, 2013 7:54:55 PM UTC+2, Ezequiel wrote:
>
> On Wednesday, September 25, 2013 3:06:55 PM UTC-3, Jorge Arevalo wrote:
>
>> Fine. I don't think my boss is going to pay for PyCharm license, so I'll 
>> probably go for Eclipse now (I don't really like it too much, but if works, 
>> it's ok for me)
>>
>
> PyCharm, which is my favorite IDE, has now a Free Community Edition: 
> https://twitter.com/pycharm/status/382549991165673472
>
> Best,
> Ezequiel
> http://flickrock.com/mikelpierre
>

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/3899d79b-7f64-451a-9ef3-f29a4d375956%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.