Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Survey and Short Dive Prometheus Operator
Search
nwiizo
May 28, 2020
Programming
2
2.2k
Survey and Short Dive Prometheus Operator
Prometheus Meetup Tokyo #4
https://prometheus.connpass.com/event/175547/
nwiizo
May 28, 2020
Tweet
Share
More Decks by nwiizo
See All by nwiizo
書を捨てよ、現場へ出よう
nwiizo
12
10k
走馬灯のIaCは考えておいて
nwiizo
8
5.2k
SREとPlatform Engineerの交差点
nwiizo
7
5.2k
SREからPlatform Engineerへの拡大
nwiizo
13
3.2k
k8sgpt Deep Dive: KubernetesクラスタのAI駆動型分析について
nwiizo
1
1.6k
Cloud Native の作法
nwiizo
8
6.4k
2023年もSRE再考と叫びなさい‼️
nwiizo
12
5.2k
自由研究には向かないウェブオペレーション
nwiizo
4
3.4k
ポストモーテムはじめました
nwiizo
3
1.5k
Other Decks in Programming
See All in Programming
코틀린으로 멀티플랫폼 만들기
pangmoo
0
120
Ruby GitHub Packages
bkuhlmann
0
620
AWS Application Composerで始める、 サーバーレスなデータ基盤構築 / 20240406-jawsug-hokuriku-shinkansen
kasacchiful
1
250
PHP8.3の機能を振り返る / Review of PHP 8.3 features
seike460
PRO
1
110
App Router への移行は「改善」となり得るのか?/ Can migration to App Router be an improvement
takefumiyoshii
8
2.1k
Netty Chicago Java User Group 2024-04-17
sullis
0
100
Designing for tomorrow's programming workflows
honnibal
PRO
2
110
Site Reliability Engineering for GMO
pyama86
6
900
大規模Reactアプリのリアーキテクチャ~8万行のTanStack Query移行の軌跡~
kj455
3
630
HUIT新歓2024「競技プログラミング、やってみませんか?」
slephy2784
1
250
StreamlitとTerraformでデータカタログを作った話
gussan0223
0
300
Javaエンジニアのための Nodejs/Nuxt3入門
hidekatsu_izuno
0
280
Featured
See All Featured
Put a Button on it: Removing Barriers to Going Fast.
kastner
58
3k
Pencils Down: Stop Designing & Start Developing
hursman
117
11k
In The Pink: A Labor of Love
frogandcode
138
21k
Building Flexible Design Systems
yeseniaperezcruz
318
37k
Done Done
chrislema
178
15k
Building Effective Engineering Teams - LeadDev
addyosmani
27
1.8k
What’s in a name? Adding method to the madness
productmarketing
PRO
15
2.6k
Art, The Web, and Tiny UX
lynnandtonic
288
19k
ReactJS: Keep Simple. Everything can be a component!
pedronauck
658
120k
Clear Off the Table
cherdarchuk
83
310k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
186
16k
From Idea to $5000 a Month in 5 Months
shpigford
377
45k
Transcript
None
None
• • •
None
None
⚫ ⚫ ⚫ https://github.com/cncf/toc/blob/master/DEFINITION.md 最近日本語が登場したので差し替えます. ありがとう @yokawasa さん
⚫ ⚫ ⚫ https://github.com/cncf/toc/blob/master/DEFINITION.md 最近日本語が登場したので差し替えます. ありがとう @yokawasa さん
• • • • 高度に発達したシステムの異常は神の怒りと見分けがつかない / IPSJ-ONE 2017 y_uuki https://speakerdeck.com/yuukit/ipsj-one-2017-y-uuki
O‘Reilly『Infrastructure as Code』より
⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫ Grafana Labs
at KubeCon: What is the Future of Observability? https://grafana.com/blog/2019/05/27/grafana-labs-at-kubecon-what-is-the-future-of-observability/
⚫ ⚫ ⚫ Grafana Labs at KubeCon: What is the
Future of Observability? https://grafana.com/blog/2019/05/27/grafana-labs-at-kubecon-what-is-the-future-of-observability/
⚫ ⚫ ⚫ ⚫ ダッシュボード 通知 設定 時系列 データベース タスク管理
観測 データ収集 データ利用 メール チャット
⚫ ⚫ ダッシュボード 通知 時系列 データベース タスク管理 観測 データ収集 データ利用
メール チャット
⚫ ⚫ 参考資料 https://microservices.io/patterns/service-registry.html https://microservices.io/ ⚫ ⚫ 後述するPromerrheus では…
• • •
None
⚫ ⚫ ⚫ ⚫
⚫ ⚫ ⚫ ⚫ ⚫
⚫ ⚫ ⚫ https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/
https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/ ⚫ ⚫ ⚫ ⚫
⚫ ⚫ ⚫ https://coreos.com/blog/introducing-operators.html https://operatorhub.io/
実践入門Kubernetes カスタムコントローラへの道 Programming Kubernetes: Developing Cloud-Native Applications
https://prometheus.io/docs/introduction/overview/ OVERVIEW
https://prometheus.io/docs/prometheus/latest/configuration/configuration/#kubernetes_sd_config
⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫
⚫ ⚫ OpenShift Monitoring - 自律化したPrometheus運用 -
⚫ https://github.com/coreos/prometheus-operator
インスタンス管理 ⚫ Prometheusデプ ロイメントを定義。 リソース定義に一 致するデプロイメ ントが常に実行さ れていることを確 認。 インスタンス管理
Alertmanagerデプ ロイメントを定義。 リソース定義に一 致するデプロイメ ントが常に実行さ れていることを確 認 ルール設定 Prometheusルー ルファイルを定義。 このファイルは、 アラートおよび記 録ルールを含む Prometheusのイ ンスタンスに ロード。 取得対象設定 サービスのグルー プを監視する方法 を宣言的に指定。 定義に基づいて Prometheus設定 ファイルの構成を 自動的に生成 取得対象設定 ポッドのグループ を監視する方法を 宣言的に指定。 定義に基づいて Prometheus設定 ファイルの構成を 自動的に生成
• • •
None
⚫ ⚫ ⚫ https://argoproj.github.io/argo-cd/
⚫ ⚫ ⚫ https://www.weave.works/technologies/gitops/
似たような環境のものが100サイト • • •
似たような環境のものが100サイト ⚫ ⚫ ⚫ ⚫
⚫ ⚫ ⚫ ⚫ ⚫
⚫ ⚫ ⚫ ⚫ ⚫ ArgoCD で同じく扱える Helmと悩んだが学習コストが少なくて済むメリットが多かった為 採用
⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫ ⚫
⚫
kube repo base 各サイト develop production
kube repo base 各サイト develop production resources: # 標準の秘密情報が載ってる -
secret.yaml # 何もデプロイされてない時の為のぺージ表示など - deployment.yaml # 80,443 サービスについて記載されている - service.yaml # 80,443 へのServiceMonitorと prometheusRule が記載 # endpoint の監視だけが監視として追加される。 - prometheusRule.yaml # commonLabelsや Annotations など
kube repo base 各サイト develop production resources: # 標準の秘密情報が載ってる -
secret.yaml # 何もデプロイされてない時の為のぺージ表示など - deployment.yaml # 80,443 サービスについて記載されている - service.yaml # 80,443 へのServiceMonitorと prometheusRule が記載 # endpoint の監視だけが監視として追加される。 - prometheusRule.yaml # commonLabelsや Annotations など ⚫
kube repo base 各サイト develop production resources: # 標準の秘密情報が載ってる -
secret.yaml # 何もデプロイされてない時の為のぺージ表示など - deployment.yaml # 80,443 サービスについて記載されている - service.yaml # 80,443 へのServiceMonitorと prometheusRule が記載 # endpoint の監視だけが監視として追加される。 - prometheusrule.yaml # commonLabelsや Annotations など ⚫
kube repo base 各サイト develop production # baseとなるkustomization.yamlを含むディレクトリ bases: -
../base # リソース名のprefix nameSuffix: "-*-gmo-jp" # patchを当てるためのファイルを指定する patches: - ./deployment.yaml # アクセス情報などは分離しておくと便利が良い resources: - ./ingress.yaml
kube repo base 各サイト develop production # baseとなるkustomization.yamlを含むディレクトリ bases: -
../base # リソース名のprefix nameSuffix: "-*-gmo-jp" # patchを当てるためのファイルを指定する patches: - ./deployment.yaml # アクセス情報などは分離しておくと便利が良い resources: - ./ingress.yaml ⚫
app repo Check app repo container repo Deploy 既存 検証環境による確認
pull req 自動生成 ※1 tag:dev kubernetes repo kustomize generate tag:dev dev.<domain> tag:prd push ※1 kustomize generate prd kube repo
⚫ ⚫ ⚫ ⚫ additionalScrapeConfigs https://github.com/coreos/prometheus-operator/blob/master/Documentation/additional-scrape-config.md additionalAlertManagerConfigs
⚫ ⚫ ⚫ ⚫
None