A prober for using with DNS server to make upgrade it to GSLB
- HCタイプを充実させる。(現在はHTTPレイヤーのみ。TCPと、pingでのHCを実装したい。)
- HCの結果をどうにかしてプロメテウス形式でエクスポートしたい。(どうやるのか)
- zoneファイルを毎秒書き換えているが、ぶっちゃけこれはGSLB_Domainに何かしらの変更が加わった時で問題ない。なので、変更があったかなかったかを確認し、なかった場合はskipする処理を入れたい。
- prometheusのダッシュボードを作る public dashboard
- 新しいEPが追加されるたびにyamlファイルとしてエクスポートされるようにしたい。
- 現在はAレコードしか張れないが、cnameも張れるようにした方がいい?いやー、まあ機能としてはあってもいいともうけど、ほぼ十はないな。逆にcnameを張ってもらう側だからな。
- UIを完成させる (いったんapiだけでいいかなーとなった)
- (coreDNSの話だが)複数のネームサーバ間でゾーンファイルが共有されるようにしたい。(nfs?自前実装??マジでムズイ。skydns形式だったらetcdが使えるのだけれども)
hc_type: 0: http 1: https 2: tcp 3: icmp
curl http://ns02.workers-bub.com:8089/v1/domain/list | jq .
make the response json tidy by using jq command.
curl -X POST "http://162.43.53.234:8089/v1/domain/add" -H "Content-Type: application/json" -d '{
"DomainName": "exmaple",
"Endpoints": [
{
"IP": "162.43.29.213",
"PORT": 443,
"HOST_HEADER": "umurphy.com",
"HCPath": "",
"HCType": 2
}
],
"HCIntervalSec": 2,
"TimeoutSec": 5,
"Password": "supersecret",
"TTL": 5
}'
The password registered here will be stored as sha256 and will be used to update/delete/add EP later as described in the following document.
assume exmaple(.workers-bub.com) is already added to the GSLB doamin
curl -X POST "http://162.43.53.234:8089/v1/domain/add" -H "Content-Type: application/json" -d '{
"DomainName": "exmaple",
"Endpoints": [
{
"IP": "162.43.29.213",
"PORT": 443,
"HOST_HEADER": "umurphy.com",
"HCPath": "",
"HCType": 2
}
],
"HCIntervalSec": 2,
"TimeoutSec": 5,
"Password": "supersecret",
"TTL": 5
}'
ensure the Password is same as the one you registered when creating the domain.
assume exmaple(.workers-bub.com) is the existing GSLB doamin
curl -X DELETE "http://162.43.53.234:8089/v1/domain/delete" -H "Content-Type: application/json" -d '{
"DomainName": "exmaple",
"Password": "supersecret"
}'
ensure the Password is same as the one you registered when creating the domain.