cope360
cope360

Reputation: 6334

How to pass dev_appserver parameters for django-nonrel

I have been using django-appengine and am now trying a project with django-nonrel. Before I used a bash script to start the local server and pass parameters.

Django-nonrel docs say you shouldn't run dev_appserver directly. Is there a way to pass these parameters?

/usr/bin/python2.5 ./dev_appserver.py \
        -p 9009 \
        -a 192.168.1.8 \
        --blobstore_path=/foo/gaedata/myapp/blobs \
        --datastore_path=/foo/gaedata/myapp/data \
        --enable_sendmail \
        $@ .

Upvotes: 3

Views: 797

Answers (2)

cope360
cope360

Reputation: 6334

  • IP address and port may be passed as the the first argument (as Robert answered)
  • --enable_sendmail works as-is
  • The datastore parameters must be separated by a space instead of an equals

Working version:

/usr/bin/python2.5 ./manage.py runserver \
        192.168.1.8:9009 \
        --enable_sendmail \
        --blobstore_path /foo/django-nonrel/blobs \
        --datastore_path /foo/data \
        --history_path /foo/history

Upvotes: 1

Robert Kluin
Robert Kluin

Reputation: 8292

If I am not mistaken, you pass the address and port in as the first arguments "192.168.1.8:9009" to your runserver command.

And/or, edit /management/commands/runserver.py and add additional parameters. I think you might be able to set the datastore and blobstore paths in your django db settings.

Also, I found one post from Waldemar commenting on this general topic.

Upvotes: 1

Related Questions