Skip to content

Instantly share code, notes, and snippets.

@liuliqiang
Created November 18, 2019 07:48
Show Gist options
  • Save liuliqiang/57fa41d1fb0d55647313d1e10f87af6c to your computer and use it in GitHub Desktop.
Save liuliqiang/57fa41d1fb0d55647313d1e10f87af6c to your computer and use it in GitHub Desktop.
fuck you
# -*- coding: utf-8 -*-
from flask import Flask, jsonify
app = Flask(__name__)
# 跨域支持
def after_request(resp):
resp.headers['Access-Control-Allow-Origin'] = '*'
return resp
app.after_request(after_request)
@app.route("/code/check")
def index():
return jsonify({"result":True,"message":"牛逼了!"})
# app.run(port=443, debug=True)
app.run(port=443, debug=True,ssl_context='adhoc')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment