# app.wsgi_app = WhiteNoise(app.wsgi_app) # app.wsgi_app.add_files('static/') app.config['FLASKS3_BUCKET_NAME'] = 'yupikmodulesweb' # app.config['FLASKS3_REGION'] = 'DEFAULT' app.config['FLASKS3_DEBUG'] = True app.config['FLASKS3_HEADERS'] = { 'Cache-Control': 'max-age=86400', } app.config['FLASKS3_ONLY_MODIFIED'] = True app.config['FLASKS3_GZIP'] = True Compress(app) s3 = FlaskS3(app) api = Api(app) api.decorators = [cors.crossdomain(origin='*', automatic_options=False)] api.methods = ['GET', 'OPTIONS', 'POST', 'PUT'] # Define parser and request args parser_api = reqparse.RequestParser() parser_api.add_argument('root', type=str) parser_api.add_argument('postbase', type=str, action='append') # FIXME obsolete # Takes a list of dict/json objects and add id field # def index(l): # new_l = [] # for i in range(len(l)): # new_x = l[i] # new_x['id'] = i # new_l.append(new_x) # return new_l