본문 바로가기

k8s39

[kubernetes/GUI] OpenLens 사용하기 (MAC) # 설치 (in MAC) brew install --cask openlens # 사용 # 쉘 접근 기능 extension 설치 @alebcay/openlens-node-pod-menu 입력 후 인스톨 끝 2023. 11. 5.
[Airflow/helm] Github OAuth 붙이기 https://artifacthub.io/packages/helm/apache-airflow/airflow airflow 1.11.0 · apache-airflow/apache-airflow The official Helm chart to deploy Apache Airflow, a platform to programmatically author, schedule, and monitor workflows artifacthub.io user-community 버전 사용하는거 아님 # 1. Github OAuth Client 만들기 homepage URL : Airflow 도메인 Authotization callback URL : Airflow 도메인 + /oauth-authorized/github # 2... 2023. 11. 5.
[superset/helm] Google OAuth 붙이기 https://artifacthub.io/packages/helm/superset/superset superset 0.10.14 · superset/superset Apache Superset is a modern, enterprise-ready business intelligence web application artifacthub.io # 1. Google OAuth 2.0 Client 만들기 승인된 자바스크립트 원본 : Superset 도메인 승인된 리디렉션 URI : Superset 도메인 + /oauth-authorized/google # 2. superset helm value 추가 configOverrides: enable_oauth: | from flask_appbuilder.securi.. 2023. 11. 5.
[ArgoCD] multiple sources 사용하기 ArgoCD를 통해 open source helm chart들을 배포할 때, values file을 text로 넣어줘야 해서 가독성이 엄청 떨어졌었다. 근데 언제부터 지원된건지 모르겠지만, 이제 multi source를 지원함으로써 external git repository로부터의 Helm value file을 사용할 수 있게 되었다....!!! 즉, airflow helm chart를 ArgoCD로 배포하려고 할 때, airflow helm value를 아래 레포지토리 경로에 저장되었다고 한다면 repository : suminhong/helm-values path : airflow/test.yaml apiVersion: argoproj.io/v1alpha1 kind: Application metada.. 2023. 11. 3.
[ArgoCD] repo-server PVC 붙이기 (w. Terraform) # argocd repo-server 란? https://argo-cd.readthedocs.io/en/stable/operator-manual/server-commands/argocd-repo-server/ Argocd repo server - Argo CD - Declarative GitOps CD for Kubernetes Argocd repo server argocd-repo-server Run ArgoCD Repository Server Synopsis ArgoCD Repository Server is an internal service which maintains a local cache of the Git repository holding the application manifests, an.. 2023. 11. 3.
[Keycloak 21] k8s cluster에 helm chart로 설치하기 bitnami 에 키클락 차트가 있다. https://artifacthub.io/packages/helm/bitnami/keycloak keycloak 17.2.0 · bitnami/bitnami Keycloak is a high performance Java-based identity and access management solution. It lets developers add an authentication layer to their applications with minimum effort. artifacthub.io # values file auth: adminUser: admin adminPassword: admin ingress: enabled: true ingressClassName: n.. 2023. 10. 29.
[Kubernetes] Graceful Shutdown - preStop 설정 # Graceful Shutdown이란? 현재 들어온 요청을 모두 수행하고 우아하게 종료한다 ... 는 개념 예를 들어, A deployment가 restart 된다고 할 때 pod B가 죽고 pod C가 새로 떠야한다고 가정해보자 service에서 pod B -> pod C 엔드포인트 변경을 해줘야 하는데, 이게 조금 늦을 수 있음 그러면 pod B는 종료되어야 하지만 여전히 pod B로 트래픽이 흘러들어갈 수 있음 -> pod B의 Application은 새로운 요청 수락만 먼저 중지하고, 모든 연결이 종료된 다음에 죽어야 함 또 다른 예시로, pod가 특정 DB와 connection을 맺고 있는 경우 해당 연결을 종료하고 죽어야 함 # Pod 종료 순서 사람 또는 시스템 : Pod 종료 API 발생.. 2023. 9. 15.
[EKS/Java/IRSA] JAVA App에 IRSA 부여할 때 종속성 추가하기 # 상황 IRSA : AWS EKS에 띄운 Application에 Pod 단위로 IAM Role을 부여하는 방법 따라서 AWS 리소스를 사용하는 Application을 쿠버에 띄울 때 IRSA 방식을 사용하면 보안적으로 좋다 근데 자바 앱들이 IRSA로 넣어준 Role을 사용하지 않고, 자꾸 EKS Node의 Role을 사용하다가 권한 에러가 났다. # 결론 sts 종속성을 추가해줘야 한다. dependencies { implementation("software.amazon.awssdk:sts:2.20.140") } # 분석 간단히 풀어 말해, IRSA 방식은 AWS STS 서비스의 AssumeRoleWithWebIdentity API 를 사용해 Role을 부여한다. -> 자바 앱들은 STS 종속성이 없.. 2023. 9. 15.
[grafana] provisioned Datasource/ContactPoint 제거 Provisioned Data Source? -> 콘솔 작업이 아닌, Config를 통해 Provisioning된 Data Source. (Contact Point도 마찬가지) 나같은 경우, grafana 공식 helm chart에서 바로 프로메테우스를 등록시켜주고 있었다. datasources: datasources.yaml: apiVersion: 1 datasources: - name: {Prometheus-Name} type: prometheus access: proxy url: {Prometheus-Url} 그러나 작성해둔 datasource를 지우고 재 배포해봐도 실제로는 삭제되지 않는다. 콘솔에서 삭제 시도 시.. Provisioned data source는 콘솔에서 못지운단다. 그럼 어떻게 .. 2023. 9. 5.
[terraform-provider-kubernetes/Issue] StorageClass ReclaimPolicy 관련 이미 생성된 Strorage Class의 경우, Reclaim Policy를 변경할 수 없다. 그러나 Terraform 으로 변경 시도 시 변경된다고 뜸 -> 실제로 변경되진 않음 Terraform으로 변경 시도 시, replacement되도록 변경되어야 한다. 이미 누가 이슈를 올려놨다. https://github.com/hashicorp/terraform-provider-kubernetes/issues/1965 Storage class reclaim_policy changes don't force recreation · Issue #1965 · hashicorp/terraform-provider-kubernetes For a plan like this: # kubernetes_storage_class.. 2023. 9. 5.