diff --git a/agent/update_catalog/skills/chart_version_detector/scripts/update_catalog/chart_version_detector.py b/agent/update_catalog/skills/chart_version_detector/scripts/update_catalog/chart_version_detector.py index e643c60..a124018 100644 --- a/agent/update_catalog/skills/chart_version_detector/scripts/update_catalog/chart_version_detector.py +++ b/agent/update_catalog/skills/chart_version_detector/scripts/update_catalog/chart_version_detector.py @@ -63,14 +63,16 @@ def _parse_repo_from_build_readme(path: Path) -> Tuple[Optional[str], Optional[s def _ensure_repo(repo: str, url: str) -> None: + # repo가 이미 등록돼 있어도 update는 항상 호출한다 — 등록만 하고 갱신을 건너뛰면 + # 로컬에 예전에 캐시된 index.yaml을 그대로 써서 latest_version이 조용히 낡은 값으로 + # 나온다(실측: secrets-operator에서 0.11.8이 나와야 할 자리에 0.11.4가 나왔다). try: out = _run(["helm", "repo", "list"]) - if repo in out: - return + if repo not in out: + _run(["helm", "repo", "add", repo, url]) except Exception: - pass - _run(["helm", "repo", "add", repo, url]) - _run(["helm", "repo", "update"]) + _run(["helm", "repo", "add", repo, url]) + _run(["helm", "repo", "update", repo]) def _latest_version(repo: str, chart: str) -> Optional[str]: diff --git a/manifests/helm/secrets-operator/0.11.8/.helmignore b/manifests/helm/secrets-operator/0.11.8/.helmignore new file mode 100644 index 0000000..0e8a0eb --- /dev/null +++ b/manifests/helm/secrets-operator/0.11.8/.helmignore @@ -0,0 +1,23 @@ +# Patterns to ignore when building packages. +# This supports shell glob matching, relative path matching, and +# negation (prefixed with !). Only one pattern per line. +.DS_Store +# Common VCS dirs +.git/ +.gitignore +.bzr/ +.bzrignore +.hg/ +.hgignore +.svn/ +# Common backup files +*.swp +*.bak +*.tmp +*.orig +*~ +# Various IDEs +.project +.idea/ +*.tmproj +.vscode/ diff --git a/manifests/helm/secrets-operator/0.11.8/BUILD-README.md b/manifests/helm/secrets-operator/0.11.8/BUILD-README.md new file mode 100644 index 0000000..81b634a --- /dev/null +++ b/manifests/helm/secrets-operator/0.11.8/BUILD-README.md @@ -0,0 +1,78 @@ +# secrets-operator 버전 갱신 가이드 + +## 1. git 작업 환경 구성 + +- DIP 카탈로그 git 다운로드 +```sh +git clone https://github.com/paasup/dip-catalog.git +``` + +- 작업 브랜치로 체크아웃 +```sh +git checkout -b update-secrets-operator/0.11.8 +``` + +## 2. helm 차트 버전 업데이트 + +- BUILD-README.md, CUSTOM-README.md, custom-values.yaml을 제외한 파일 삭제 +```sh +# chart 디렉토리로 이동 +cd ~/dip-catalog/manifests/helm/secrets-operator/0.11.8 + +# 삭제할 파일 목록 확인 +find . -mindepth 1 \( -name "CUSTOM-README.md" -o -name "BUILD-README.md" -o -name "custom-values.yaml" \) -prune -o -print + +# 파일 삭제 +find . -mindepth 1 \( -name "CUSTOM-README.md" -o -name "BUILD-README.md" -o -name "custom-values.yaml" \) -prune -o -exec rm -rf {} + +``` + +- secrets-operator 차트 다운로드 +```sh +# manifests/helm/secrets-operator 디렉토리로 이동 +cd ~/dip-catalog/manifests/helm/secrets-operator + +# helm repo 추가 +helm repo add infisical-helm-charts https://dl.cloudsmith.io/public/infisical/helm-charts/helm/charts/ +helm repo update + +# helm 차트 pull +helm pull infisical-helm-charts/secrets-operator --version="0.11.8" + +# 차트 압축 해제 +tar xzvf secrets-operator-0.11.8.tgz + +# 압축 파일 삭제 +rm secrets-operator-0.11.8.tgz +``` + +## 3. git push 및 tag 추가 + +- 갱신작업 진행 후 commit +```sh +git add . +git commit -m "update secrets-operator/0.11.8" +``` + +- main 브랜치에 체크아웃 후 merge +```sh +git checkout main +git merge update-secrets-operator/0.11.8 +``` + +- git에 push 후 작업 브랜치 삭제 +```sh +git push -u origin main +git branch -d update-secrets-operator/0.11.8 +``` + +- git tag 추가 후 push +```sh +git tag secrets-operator/0.11.8 +git push origin secrets-operator/0.11.8 +``` + +## 4. 차트 버전 정보 + +- secrets-operator/0.11.8 (app version: 0.11.8) + - Infisical Secrets Operator (InfisicalSecret CRD 로 시크릿을 클러스터에 동기화) + - infisical-standalone 과 짝을 이루어 설치한다. diff --git a/manifests/helm/secrets-operator/0.11.8/CUSTOM-README.md b/manifests/helm/secrets-operator/0.11.8/CUSTOM-README.md new file mode 100644 index 0000000..0123ffc --- /dev/null +++ b/manifests/helm/secrets-operator/0.11.8/CUSTOM-README.md @@ -0,0 +1,53 @@ +# Upgrade History + +## v0.10.33 → 0.11.8 +### 변경 요약 +- from_version: v0.10.33 +- to_version: 0.11.8 +- Chart `secrets-operator` v0.10.33 → 0.11.8 업데이트 +- Values: +0 / -0 / ~1 / type~0 +- Templates: +3 / -0 +- Dependencies: +0 / -0 / ~0 + +### custom-values.yaml 수정 필요 항목 +없음 (이 차트는 애초에 custom-values.yaml이 없다 — 차트 기본값만 씀) + +### CVE 실측 (업그레이드 트리거) +이미지 `infisical/kubernetes-operator`를 trivy(+CoverageProbe 자가진단)로 직접 스캔한 결과: + +| 버전 | OS | 커버리지 | 실효 HIGH(차단) | +|---|---|---|---:| +| v0.10.33 | debian 13.4 | ✅ ok | 34 | +| v0.11.8 | debian 13.6 | ✅ ok | 10 | + +CRITICAL은 둘 다 0건. 34건 중 24건이 해소됨(대부분 stdlib·golang.org/x/net·x/crypto — +빌더 Go 툴체인이 올라가며 해소된 것으로 보임). 둘 다 `CoverageProbe: ok`라 이 수치는 +실측이지 데이터 부재로 인한 거짓 clean이 아니다. + +### 신규 CRD 3개 — `⚠️ 업그레이드 시 helm이 CRD를 자동 적용하지 않을 수 있다` +`InfisicalAuth`·`InfisicalConnection`·`InfisicalStaticSecret`가 새로 추가됐다 +(`infisicalauths.secrets.infisical.com` 등). helm은 기존 릴리스 업그레이드 시 CRD를 +자동으로 설치/갱신하지 않는 경우가 있다(helm 자체의 알려진 제약) — 업그레이드 후 +`kubectl get crd | grep infisical`로 3개가 실제로 생겼는지 반드시 확인한다. + +### 참고 +- severity: warning +- breaking: false + +# secrets-operator 배포 가이드 + +## 개요 + +Infisical Secrets Operator. `InfisicalSecret` CRD 를 감시해 Infisical 에 저장된 시크릿을 +클러스터 Secret 으로 동기화한다. `infisical-standalone` 과 짝을 이루어 설치한다. + +## custom-values + +없다 — 차트 기본값을 그대로 쓴다. + +## 주의사항 + +- 설치 순서: `infisical-standalone` 이 먼저 떠 있어야 오퍼레이터가 인증에 성공한다. +- 인증에는 Universal Auth(machine identity) 또는 Kubernetes Auth 를 쓴다. 사설 클러스터에서 + Kubernetes Auth 를 등록하려면 백엔드 쪽에 `ALLOW_INTERNAL_IP_CONNECTIONS=true` 가 필요하다 + (infisical-standalone 의 CUSTOM-README 참고). diff --git a/manifests/helm/secrets-operator/0.11.8/Chart.yaml b/manifests/helm/secrets-operator/0.11.8/Chart.yaml new file mode 100644 index 0000000..75e43ae --- /dev/null +++ b/manifests/helm/secrets-operator/0.11.8/Chart.yaml @@ -0,0 +1,6 @@ +apiVersion: v2 +appVersion: v0.11.8 +description: A Helm chart for Infisical secrets +name: secrets-operator +type: application +version: v0.11.8 diff --git a/manifests/helm/secrets-operator/0.11.8/README.md b/manifests/helm/secrets-operator/0.11.8/README.md new file mode 100644 index 0000000..6886706 --- /dev/null +++ b/manifests/helm/secrets-operator/0.11.8/README.md @@ -0,0 +1,99 @@ +# Infisical Helm Chart + +This is the Infisical Secrets Operator Helm chart. Find the integration documentation [here](https://infisical.com/docs/integrations/platforms/kubernetes) + +## Installation + +To install the chart, run the following : + +```sh +# Add the Infisical repository +helm repo add infisical 'https://dl.cloudsmith.io/public/infisical/helm-charts/helm/charts/' && helm repo update + +# Install Infisical Secrets Operator (with default values) +helm upgrade --install --atomic \ + -n infisical-dev --create-namespace \ + infisical-secrets-operator infisical/secrets-operator + +# Install Infisical Secrets Operator (with custom inline values, replace with your own values) +helm upgrade --install --atomic \ + -n infisical-dev --create-namespace \ + --set controllerManager.replicas=3 \ + infisical-secrets-operator infisical/secrets-operator + +# Install Infisical Secrets Operator (with custom values file, replace with your own values file) +helm upgrade --install --atomic \ + -n infisical-dev --create-namespace \ + -f custom-values.yaml \ + infisical-secrets-operator infisical/secrets-operator +``` + +## Synchronization + +To sync your secrets from Infisical (or from your own instance), create the below resources : + +```sh +# Create the tokenSecretReference (replace with your own token) +kubectl create secret generic infisical-example-service-token \ + --from-literal=infisicalToken="" + +# Create the InfisicalSecret +cat <