2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

GCPロードバランシングでssl化したもののGCEインスタンスのflaskにアクセスできなかった日

Last updated at Posted at 2019-10-03

##前提&状況
・flask
・google compute engine
・loadbalancing
あとでかく

###解決策
ライブラリ(SSLify)を追加

$ pip install Flask-SSLify

github見ながらよしなに書き込む

from flask import Flask
from flask_sslify import SSLify

app = Flask(__name__)
sslify = SSLify(app)

##SUCCESS!!

####参考
https://github.com/kennethreitz/flask-sslify
Python+Flaskで、全てのリクエストをHTTPSにリダイレクト「Flask-SSLify」

2
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?