keys
V2EX  ›  问与答

有谁在sae上成功搭建了django1.42版本构建的网站,秀下你的index.wsgi,我快崩溃了

  •  
  •   keys · Dec 10, 2012 · 3776 views
    This topic created in 4899 days ago, the information mentioned may be changed or developed.
    4 replies    1970-01-01 08:00:00 +08:00
    c
        1
    c  
       Dec 10, 2012
    name: ***
    version: 1

    libraries:
    - name: django
    version: "1.4"
    xingzhi
        2
    xingzhi  
       Dec 10, 2012
    搭建了1.4的,不知道是不是你说的1.42
    XXX 是我的项目名。


    config.yaml:

    ---
    name: XXX
    version: 1

    libraries:
    - name: "django"
    version: "1.4"

    handlers:
    - url: /static
    static_dir: /XXX/static
    ...



    index.wsgi:

    import sae

    from XXX import wsgi

    application = sae.create_wsgi_app(wsgi.application)
    c
        3
    c  
       Dec 10, 2012
    #!/usr/bin/env python
    # coding:utf-8

    import os

    import django.core.handlers.wsgi
    import sae
    os.environ['DJANGO_SETTINGS_MODULE'] = 'sae_119797.settings_sae'
    application = sae.create_wsgi_app(django.core.handlers.wsgi.WSGIHandler())
    keys
        4
    keys  
    OP
       Dec 10, 2012
    github上有个1.4的事例,没有1.4.2的,我试过,don't work
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   2708 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 15:57 · PVG 23:57 · LAX 08:57 · JFK 11:57
    ♥ Do have faith in what you're doing.