Example #1
0

#####################################
## Mail
#####################################
if RUNTIME_ENV in ("bae",):
    from bae.api.bcms import BaeBcms

    BAE_BCMS = BaeBcms(const.ACCESS_KEY, const.SECRET_KEY)

elif RUNTIME_ENV in ("local",):
    app.config["MAIL_SERVER"] = "localhost"
    app.config["MAIL_PORT"] = 25
    app.config["MAIL_USE_TLS "] = False
    app.config["MAIL_USE_SSL "] = False
    app.config["MAIL_USERNAME "] = "test"
    app.config["MAIL_PASSWORD "] = "test"

    from flask_mail import Mail

    mail = Mail(app)

elif RUNTIME_ENV in ("gae", "gae_dev"):
    pass

#####################################
## Image Upload
#####################################
if RUNTIME_ENV in ("bae",):
    from bae.api import bcs