如何为 django-nonrel 传递 dev_appserver 参数
我一直在使用 django-appengine,现在正在尝试使用 django-nonrel 的项目。之前我使用bash脚本来启动本地服务器并传递参数。
Django-nonrel 文档 说你不应该直接运行 dev_appserver 。有没有办法传递这些参数?
/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 \
$@ .
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 \
$@ .
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
如果我没有记错的话,您可以将地址和端口作为第一个参数“192.168.1.8:9009”传递给 runserver 命令。
和/或,编辑
/management/commands/runserver。 py
并添加其他参数。我认为您也许可以在 django 数据库设置中设置数据存储和 blobstore 路径。另外,我还发现 Waldemar 发表了一篇帖子,对这个一般性主题进行了评论。
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.
工作版本:
Working version: