免责声明:我已经问过here,但显然是偏离主题。
我想使用this引导程序模板设置页面,并使用google appengine服务将其作为静态网站托管。
在google_appengine目录中,我使用页面数据和 app.yaml 创建了一个文件夹 page :
app.yaml将此作为内容:
application: coolmoon
version: 1
runtime: python27
api_version: 1
threadsafe: yes
handlers:
- url: /(.+)
static_files: public/\1
upload: public/(.*)
- url: /
static_files: public/index.html
upload: public/index.html
skip_files:
- ^(.*/)?app\.yaml
- ^(.*/)?app\.yml
- ^(.*/)?#.*#
- ^(.*/)?.*~
- ^(.*/)?.*\.py[co]
- ^(.*/)?.*/RCS/.*
- ^(.*/)?\..*
- ^(.*/)?tests$
- ^(.*/)?test$
- ^test/(.*/)?
- ^COPYING.LESSER
- ^README\..*
- \.gitignore
- ^\.git/.*
- \.*\.lint$
- ^fabfile\.py
- ^testrunner\.py
- ^grunt\.js
- ^node_modules/(.*/)?
当我进入google_appengine文件夹并运行
时python dev_appserver.py page
我收到错误消息
Traceback (most recent call last): File "dev_appserver.py", line 82,
in <module>
_run_file(__file__, globals()) File "dev_appserver.py", line 78, in _run_file
execfile(_PATHS.script_file(script_name), globals_) File "/home/bogus/webpage/google_appengine/google/appengine/tools/devappserver2/devappserver2.py",
line 943, in <module>
main() File "/home/bogus/webpage/google_appengine/google/appengine/tools/devappserver2/devappserver2.py",
line 936, in main
dev_server.start(options) File "/home/bogus/webpage/google_appengine/google/appengine/tools/devappserver2/devappserver2.py",
line 695, in start
options.config_paths) File "/home/bogus/webpage/google_appengine/google/appengine/tools/devappserver2/application_configuration.py",
line 617, in __init__
config_paths = self._config_files_from_paths(config_paths) File "/home/bogus/webpage/google_appengine/google/appengine/tools/devappserver2/application_configuration.py",
line 682, in _config_files_from_paths
self._config_files_from_dir(path) if os.path.isdir(path) else [path]) File
"/home/bogus/webpage/google_appengine/google/appengine/tools/devappserver2/application_configuration.py",
line 710, in _config_files_from_dir
(dir_path, or_web_inf)) google.appengine.tools.devappserver2.errors.AppConfigNotFoundError:
"page/" is a directory but does not contain app.yaml or app.yml
但是app.yaml肯定在文件夹 page
中出了什么问题?
我的命令是否正确?
答案 0 :(得分:0)
为什么不使用Amazon S3或类似的服务?它更适合这种事情。