私のドメインのホストゾーンのリソースレコードタイプAの外部IPを更新しようとすると、コマンドラインのGoogle Cloud DNSを使用するとエラーが発生します... this works fine using the browser based gce console ...英語私がKubernetesを使ってアプリケーションをデプロイすると、私は自分のドメイン(example.com)でブラウザを指し示す私のアプリに人々がアクセスできるように、私は既存のドメインDNSにリンクする必要がある新鮮なIPを与える...この行動は起こる必要がある毎回アプリを再デプロイするときに自動化する必要がありますgcloud dnsレコードセットトランザクションIPアドレスを更新できません
注 - クラウドDNSゾーンは既に存在し、機能しています。 Iここ
kubectl describe svc --namespace=ruptureofthemundaneplane | grep Ingress
LoadBalancer Ingress: 104.196.108.178
ごとに新鮮なKubernetes展開のロードバランサ侵入を一致させるために、外部IPアドレスを更新しようとすると、現在の状態がここ
gcloud dns record-sets list --zone zone-cubalibre --project ruptureofthemundaneplane
NAME TYPE TTL DATA
example.com. A 60 104.196.108.147
example.com. NS 60 ns-cloud-a1.googledomains.com.,ns-cloud-a2.googledomains.com.,ns-cloud-a3.googledomains.com.,ns-cloud-a4.googledomains.com.
example.com. SOA 60 ns-cloud-a1.googledomains.com. cloud-dns-hostmaster.google.com. 1 21600 3600 1209600 300
admin.example.com. CNAME 60 example.com.
www.admin.example.com. CNAME 60 example.com.
www.example.com. CNAME 60 example.com.
で午前は、単に記録
gcloud dns record-sets list --project ruptureofthemundaneplane --zone zone-cubalibre --name "example.com." --type "A"
NAME TYPE TTL DATA
example.com. A 60 104.196.108.147
を入力していますIP 104.196.108.147を新しい値104.196.108.178に置き換える必要があります...発行します
gcloud dns record-sets transaction start --zone zone-cubalibre --project ruptureofthemundaneplane
ここで私は私の新しいIPアドレスここ
gcloud dns record-sets transaction add "104.196.108.178" --name "example.com." --ttl 60 --type "A" --project ruptureofthemundaneplane --zone zone-cubalibre
との取引システムは、私は、トランザクション・キャッシュ
を表示するシステムを頼むここに完全を期すためcat transaction.yaml
---
additions:
- kind: dns#resourceRecordSet
name: example.com.
rrdatas:
- ns-cloud-a1.googledomains.com. cloud-dns-hostmaster.google.com. 2 21600 3600 1209600
300
ttl: 60
type: SOA
- kind: dns#resourceRecordSet
name: example.com.
rrdatas:
- 104.196.108.178
ttl: 60
type: A
deletions:
- kind: dns#resourceRecordSet
name: example.com.
rrdatas:
- ns-cloud-a1.googledomains.com. cloud-dns-hostmaster.google.com. 1 21600 3600 1209600
300
ttl: 60
type: SOA
YAMLファイルを生成している追加
gcloud dns record-sets transaction describe --project ruptureofthemundaneplane --zone zone-cubalibre
...出力
additions:
- kind: dns#resourceRecordSet
name: example.com.
rrdatas:
- ns-cloud-a1.googledomains.com. cloud-dns-hostmaster.google.com. 2 21600 3600 1209600
300
ttl: 60
type: SOA
- kind: dns#resourceRecordSet
name: example.com.
rrdatas:
- 104.196.108.178
ttl: 60
type: A
deletions:
- kind: dns#resourceRecordSet
name: example.com.
rrdatas:
- ns-cloud-a1.googledomains.com. cloud-dns-hostmaster.google.com. 1 21600 3600 1209600
300
ttl: 60
type: SOA
は最終的に私はこの
gcloud dns record-sets transaction execute --project ruptureofthemundaneplane --zone zone-cubalibre
ERROR: (gcloud.dns.record-sets.transaction.execute)
The resource 'entity.change.additions[1]' named 'example.com. (A)' already exists (code: 409)
任意の提案でトランザクションをコミット?私はそれがスケーラブルではないとして静的IPを事前に定義しないようにしたい... the equivalent Amazon aws commands work when I deploy using kube-up.sh over aws ... kubernetesがすべてのクラウドホストベンダーで共通のソリューションを達成した場合、素敵なタッチになるでしょう...これを達成するために他の自動手段を使用しているのですか? lang xのいくつかのSDKライブラリ?