Giter Club home page Giter Club logo

alertmanager-test's Introduction

Prometheus Alertmanager のテスト用 docker-compose

起動方法

docker-compose up

http://$(docker-machine ip):9093/ で Alertmanager の Web UI に、 http://$(docker-machine ip):8025/ で Mailhog にアクセスできる (Basic 認証は user / password)。docker-machine でない場合は適宜読みかえ。

webhook はログで確認

docker-compose exec alertmanager amtool --alertmanager.url http://localhost:9093/ alert

などとして amtool でアクセス可能

メモ

MailHog のSMTP Auth 用パスワード生成

alertmanager の SMTP クライアントは認証設定しないとメールを送ってくれない (EHLO のレスポンスを受けた後にすぐ QUIT を送る) ようなので Mailhog に SMTP AUTH 対応させる

password ファイルには bcrypt で生成する hash を書く必要があり、hash 値は次のようにして計算できる

docker run --rm -it mailhog/mailhog:v1.0.0 bcrypt password-string

Ghostunnel で SMTP over SSL 対応

Go の SMTP クライアントが SMTP AUTH で PLAIN Method を使う場合には 通信の暗号化を必須とするため Ghostunnel で SMTP over SSL にする

alertmanager の SMTP クライアントは port が 465 の場合にのみ SSL/TLS での 接続をこころみるため、Ghostunnel コンテナが expose するポートは 465 にする必要がある

Ghostunnel で使うサーバー証明書の作成

PKCS12 フォーマットにする必要がある

bash mkcert.sh

alertmanager-test's People

Contributors

yteraoka avatar

Watchers

 avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.