Wednesday, December 29, 2010

Re: django and eclipse

To run Django server on specific IP and port you can use following
command:

python manage.py runserver <IP>:<port>

e.g. python manage.py runserver 11.12.13.145:5678

If you do not specify IP and the port it starts on
localhost(127.0.0.1) and port 8000.

If you are using command prompt and do not want to use it, you can use
eclipse for the same, following link is useful for this:

http://www.magpiebrain.com/2006/10/09/using-eclipse-and-pydev-for-django/

--Rajendra.

On Dec 30, 10:05 am, girish shabadimath <girishmss.1...@gmail.com>
wrote:
> to change port:
> django-admin.py runsserver <new port number>
>
> On Thu, Dec 30, 2010 at 6:24 AM, Emmanuel Mayssat <emays...@gmail.com>wrote:
>
>
>
> > For the sqlite.db file issue, I changed the settings.py with:
>
> > import os
> > PROJECT_DIR = os.path.dirname(__file__)
> > ...
> > DATABASE_ENGINE = 'sqlite3'
> > DATABASE_NAME = os.path.join(PROJECT_DIR, 'sqlite.db')
>
> > that now works as expected.
> > --
> > Emmanuel Mayssat
>
> > On Wed, Dec 29, 2010 at 4:38 PM, Emmanuel Mayssat <emays...@gmail.com>
> > wrote:
> > > I installed the pydev plugin in eclipse.
> > > I configured it.
> > > Imported my django project and it almost works.
>
> > > Is any one of you using django/eclipse?
>
> > > Well, all goes well until I start the django development server.
> > > 1/ how can I change the default port, it is running on ?
> > > 2/ My sqlite db files is regenerated by the runserver (I had never
> > > seen  that!) in a different directory (at the project level).
> > > If I symlink the 2 db files, it works as expected.
> > > Any clue?
>
> > > BTW, I noticed that when creating a django project in eclipse, it ask
> > > for the path to the db files (when using sqlite3)
> > > It is configured to point to the right location, but runserver doesn't
> > get that.
> > > So what is this db file path used for ? (settings.py is created but
> > > not even configured...)
>
> > > --
> > > Emmanuel Mayssat
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "Django users" group.
> > To post to this group, send email to django-users@googlegroups.com.
> > To unsubscribe from this group, send email to
> > django-users+unsubscribe@googlegroups.com<django-users%2Bunsubscribe@googlegroups.com>
> > .
> > For more options, visit this group at
> >http://groups.google.com/group/django-users?hl=en.
>
> --
> Girish M S

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.

No comments:

Post a Comment