Skip to content

Latest commit

 

History

History
70 lines (50 loc) · 1.17 KB

README.md

File metadata and controls

70 lines (50 loc) · 1.17 KB

mainfest

事前準備

1. ageで鍵生成

age-keygen -o keys.txt 

2. 公開鍵を.sops.yamlに突っ込む

3. 鍵を移動

macOS

mkdir -p "$HOME/Library/Application Support/sops/age"
mv keys.txt "$HOME/Library/Application Support/sops/age"

Linux

mkdir -p "$XDG_CONFIG_HOME/sops/age"
mv keys.txt"$XDG_CONFIG_HOME/sops/age"
mv keys.txt 

secretの入れ方

1. 暗号化

sops -e some-secret.yaml > some-secret.enc.yaml

2. 設定

ksops.yaml

apiVersion: viaduct.ai/v1
kind: ksops
metadata:
  name: ksops
  annotations:
    config.kubernetes.io/function: |
      exec:
        path: ksops
files:
  - ./secrets/some-secret.enc.yaml

Bootstrap

1. sops用secret作成

kubectl create secret generic sops-age --namespace=argocd --from-file="$HOME/Library/Application Support/sops/age/keys.txt"

2. argocdnginx-ingressをデプロイ

kubectl create ns argocd
kustomize build . --enable-alpha-plugins --enable-exec --enable-helm | kubectl apply -n argocd -f -

3. ArgoCDのUIからリポジトリなど設定

4. argocdnginx-ingressを含む各アプリをSync