2025年2月20日木曜日

Redis(helm install)

local-storage は 動的プロビジョニングされない ため、Helm のインストール時に PersistentVolume (PV) を事前に作成する必要があります


手順:
1)strage classをlocal strageを指定
helm install my-redis bitnami/redis --set global.storageClass=local-storage

2)PVは作成してくれないので以下に作成
apiVersion: v1
kind: PersistentVolume
metadata:
name: redis-pv
spec:
capacity:
storage: 8Gi
accessModes:
- ReadWriteOnce
persistentVolumeReclaimPolicy: Retain
storageClassName: local-storage
local:
path: /mnt/data/redis
nodeAffinity:
required:
nodeSelectorTerms:
- matchExpressions:
- key: kubernetes.io/hostname
operator: In
values:
- rasp-node1 # 実際に使用するノード名に変更
- rasp-node2
---
apiVersion: v1
kind: PersistentVolume
metadata:
name: redis-pv2
spec:
capacity:
storage: 8Gi
accessModes:
- ReadWriteOnce
persistentVolumeReclaimPolicy: Retain
storageClassName: local-storage
local:
path: /mnt/data/redis
nodeAffinity:
required:
nodeSelectorTerms:
- matchExpressions:
- key: kubernetes.io/hostname
operator: In
values:
- rasp-node1 # 実際に使用するノード名に変更
- rasp-node2
---
apiVersion: v1
kind: PersistentVolume
metadata:
name: redis-pv3
spec:
capacity:
storage: 8Gi
accessModes:
- ReadWriteOnce
persistentVolumeReclaimPolicy: Retain
storageClassName: local-storage
local:
path: /mnt/data/redis
nodeAffinity:
required:
nodeSelectorTerms:
- matchExpressions:
- key: kubernetes.io/hostname
operator: In
values:
- rasp-node1 # 実際に使用するノード名に変更
- rasp-node2
---
apiVersion: v1
kind: PersistentVolume
metadata:
name: redis-pv4
spec:
capacity:
storage: 8Gi
accessModes:
- ReadWriteOnce
persistentVolumeReclaimPolicy: Retain
storageClassName: local-storage
local:
path: /mnt/data/redis
nodeAffinity:
required:
nodeSelectorTerms:
- matchExpressions:
- key: kubernetes.io/hostname
operator: In
values:
- rasp-node1 # 実際に使用するノード名に変更
- rasp-node2

0 件のコメント:

コメントを投稿

istio ingress gateway(指定したEnvoyプロキシが接続しているクラスターの情報表示)

指定した Envoy プロキシが接続しているクラスターの情報を表示しています。 出力からは、Envoy プロキシがどのサービスに対して接続設定を持っているか またはどのサービスとの通信が行われているかを確認できます。 [出力の説明] SERVICE FQDN :  接続先サービス...