FuFu KK8s
  • K~K8s index
  • Kubernetes 的基礎世界
  • Why container is not Docker
  • Startup Local Kubernetes via Minikube
  • K8s Master node Component 介紹
  • NameSpace、Deployments 概念說明
  • 常見的 kubectl 指令
  • 回顧第一次部署,淺談 Pod、Deployment
  • 回顧第一次部署,淺談 Service
  • 今日來介紹 Pod 靜態文件~ Manifest
  • Pod 的健康檢查方式
  • Pod 的健康檢查方式 Part-2
  • Pod 的資源請求、上限
  • Pod 資料,如何持久化存放、讀取
  • Pod 副本管理~ 描述 ReplicaSet 控制器
  • Pod 副本管理~ 實作篇
  • 淺談 DaemonSet,及相對 ReplicaSet 的差異
  • 來說說 Label
  • 從 Label 再回頭談 Service
  • Service 續集之 Cluster IP、Kube-proxy、LoadBalancer
  • 從 Service 發現 K8s 網路層全貌
  • Container Data Persistent
  • 發現、初談 StatefulSet
  • 再談 StatefulSet
  • 認識 ConfigMap
  • 第一次使用 Play with Kubernetes
  • 手工 Installing kubeadm
  • 手工 Installing CRI-O、kubeadm init
  • 繼上篇,排查 kubelet、kubeadm init 問題
  • Installing a pod network add-on
  • K8s add Nodes(join)
  • 驗證自建的 K8s
  • 筆記
    • kubectl get 筆記
    • kubectl 部署筆記
    • kubectl describe nodes
  • 實務記憶篇
    • 整理下記憶
    • 有哪些 Kubernetes 雲端服務
    • 如何從本機連線至 GKE Pod
    • GCP Memorystore 服務介紹
    • 如何連線至 GCP Memorystore
    • GCP Cloud SQL 服務介紹
    • 如何連線至 Cloud SQL
    • 關於 GCP VPC 網路
    • HELM 工具用途
    • 臨時題目:查修 prometheus
    • 繼續離題:繼續查修Prometheus
    • 臨時題目:限定 Pod 訪問外網時,固定 public ip
    • K8s 監控數據來源 Prometheus
    • 監控要告警啊 AlertManager
    • 監控要有圖表啊 Grafana
    • Grafana收集Kubernetes系統資訊
    • 系統 Log 資料
    • 系統 Log 資料收集至 EFK
    • 關於 EFK 角色
    • 系統 Log 資料 - fluent-bit 串接
    • 開放網站對外存取
    • 網站提供 https 安全連線服務 - 憑證管理
    • 網站提供 https 安全連線服務 - 憑證與Ingress整合
    • 網站提供 https 安全連線服務 - Istio 範例
    • 需要額外的 非http 連線
    • Istio 初略介紹
    • Istio 整合 Certmanager DNS01
    • 番外篇:Istio 如何限制訪問來源
    • 番外篇:如何擴充 PV PVC storage size
    • 番外篇:如何利用 Binlog 還原資料庫
  • Helm 實務學習心得
    • Helm requirements 見解
    • 同環境,一次部署多個相同App
  • Python
    • 11-1 Firebase 資料庫簡介
Powered by GitBook
On this page
  • Cert-maneger 架構
  • Issuer
  • Certificates
  1. 實務記憶篇

網站提供 https 安全連線服務 - 憑證管理

Previous開放網站對外存取Next網站提供 https 安全連線服務 - 憑證與Ingress整合

Last updated 5 years ago

HTTPS 服務的入口,在K8s環境中當然不可缺少入口與憑證兩大元素,關於"入口",可以在中複習下~

在K8s環境中,印行憑證管理、或者透過申請,蠻好用的一個控制器就是 cert-manager

Cert-maneger 架構

從上圖中,主要兩個新元素資源:Issuer、Certificates

Issuer

apiVersion: certmanager.k8s.io/v1alpha1
kind: Issuer
metadata:
  name: letsencrypt-prod
  namespace: edge-services
spec:
  acme:
    # The ACME server URL
    server: https://acme-v02.api.letsencrypt.org/directory
    # Email address used for ACME registration
    email: user@example.com
    # Name of a secret used to store the ACME account private key
    privateKeySecretRef:
      name: letsencrypt-prod
    # Enable HTTP01 validations
    http01: {}

Certificates

此資源用途可以想像為憑證申請表的意思~ 其內容定義:申請網域or網址(dnsNames、acme)、指定憑證發行機構(issuerRef),概念如下:

apiVersion: certmanager.k8s.io/v1alpha1
kind: Certificate
metadata:
  name: acme-crt
spec:
  secretName: acme-crt-secret
  dnsNames:
  - foo.example.com
  - bar.example.com
  acme:
    config:
    - http01:
        ingressClass: nginx
      domains:
      - foo.example.com
      - bar.example.com
  issuerRef:
    name: letsencrypt-prod
    # We can reference ClusterIssuers by changing the kind here.
    # The default value is Issuer (i.e. a locally namespaced Issuer)
    kind: Issuer

以上,當您定義好兩項資源與套用後,即可向憑證商提出申請,如順利即可獲得您網站所需的 SSL 憑證。此憑證最終會存放於K8s Secret資源中。

其用途是 憑證(x509 certificates) 申請機構代表,例如 其中定義了機構的窗口(server)、申請者(email)、申請方式(HTTP01 or DNS01)等等,概念如下:

Let’s Encrypt
此篇文章