# Kubernetes での SSL 設定方法

**URL:** https://meta.discourse.org/t/how-to-set-up-ssl-on-kubernetes/149112
**Category:** Self-hosting
**Tags:** unsupported-install
**Created:** [2020 年 4 月 24 日午前 7:24 UTC](https://meta.discourse.org/t/how-to-set-up-ssl-on-kubernetes/149112 "2020-04-24T07:24:47Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![Harsh\_Pratap\_Singh](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/harsh_pratap_singh/32/178069_2.png) [@Harsh\_Pratap\_Singh](https://meta.discourse.org/u/Harsh_Pratap_Singh)
#### Post date: [2020 年 4 月 24 日午前 7:24 UTC](https://meta.discourse.org/t/how-to-set-up-ssl-on-kubernetes/149112/1 "2020-04-24T07:24:47Z")

</div>

こんにちは。  
Kubernetes に Discourse をセットアップしました。設定は完全に稼働していますが、サイトはまだ HTTP のままです。HTTPS へ移行したいと考えています。  
至急ご支援をお願いします。

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [2020 年 4 月 24 日午後 7:42 UTC](https://meta.discourse.org/t/how-to-set-up-ssl-on-kubernetes/149112/2 "2020-04-24T19:42:01Z")

</div>

お任せします。ここでは Kubernetes はサポートされていません。

これは Discourse の問題ではなく、Kubernetes/ingress の問題です。したがって、k8s や ingress の専門家がいる場所で質問してください。

サポートを受けるには、k8s をどこで実行しているか（または、お使いのプラットフォーム固有の場所で質問）を伝える必要があります。https ingress を有効にする方法は、プラットフォーム（GKE、Amazon のサービス、ベアメタルなど）によって異なるためです。

---

<div class="post-metadata">

### Author: ![Falco](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/falco/32/179432_2.png) [@Falco](https://meta.discourse.org/u/Falco)
#### Post date: [2020 年 4 月 24 日午後 7:43 UTC](https://meta.discourse.org/t/how-to-set-up-ssl-on-kubernetes/149112/3 "2020-04-24T19:43:45Z")

</div>

設定 `force_https` を有効にしましたか？

---

<div class="post-metadata">

### Author: ![pfaffman](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/pfaffman/32/120154_2.png) [@pfaffman](https://meta.discourse.org/u/pfaffman)
#### Post date: [2020 年 4 月 24 日午後 7:56 UTC](https://meta.discourse.org/t/how-to-set-up-ssl-on-kubernetes/149112/4 "2020-04-24T19:56:43Z")

</div>

それだけで済むことを願っています！あなたの提案は必要ですが、それだけでは不十分かもしれません。ただし、https の設定が整った後であれば、確かに手順を一つ省略できるでしょう。私は数週間、オンオフを繰り返しながら、裸の金属サーバー上の k8s 環境で https によるイングレスを機能させるために格闘してきました。GKE（おそらく AWS も同様）では、ガイドに従うだけで比較的簡単に設定できます。

---

<div class="post-metadata">

### Author: ![Harsh\_Pratap\_Singh](https://sea3.discourse-cdn.com/meta/user_avatar/meta.discourse.org/harsh_pratap_singh/32/178069_2.png) [@Harsh\_Pratap\_Singh](https://meta.discourse.org/u/Harsh_Pratap_Singh)
#### Post date: [2020 年 4 月 28 日午前 4:27 UTC](https://meta.discourse.org/t/how-to-set-up-ssl-on-kubernetes/149112/5 "2020-04-28T04:27:25Z")

</div>

こんにちは、@pfaffman さん。  
現在、私はイングレスを使ってルーティングしていません。LB サービスを作成し、その LB IP を私のドメインにマッピングしました。  
さらに、私のドメイン用の証明書も生成しました。唯一の問題は、Discourse 内に証明書をどのディレクトリに配置すべきかという点です。  
ディレクトリ構造は少し異なりますが、すべてのファイルは同じです。
