Skip to content

Commit

Permalink
环境变量支持配置CORS_ALLOWED_ORIGINS
Browse files Browse the repository at this point in the history
  • Loading branch information
qwIvan committed Apr 15, 2021
1 parent a41b237 commit 4bb58fb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion micro_msg_bot/server.py
Expand Up @@ -10,7 +10,7 @@

app = Flask(__name__)
app.secret_key = os.environ.get('KEY', 'YOUR_SECRET_KEY')
socketio = SocketIO(app)
socketio = SocketIO(app, cors_allowed_origins=os.environ.get('CORS_ALLOWED_ORIGINS', None))


@app.route('/')
Expand Down

0 comments on commit 4bb58fb

Please sign in to comment.