Index: gs3-extensions/vm-manager/trunk/src/append-dns-zone/README.txt
===================================================================
--- gs3-extensions/vm-manager/trunk/src/append-dns-zone/README.txt	(revision 38649)
+++ gs3-extensions/vm-manager/trunk/src/append-dns-zone/README.txt	(revision 38649)
@@ -0,0 +1,94 @@
+Based on general Cloud DNS overview
+  https://cloud.google.com/dns/docs/set-up-dns-records-domain-name
+
+And:
+
+  https://cloud.google.com/dns/docs/update-name-servers
+
+gcloud dns --project=atea-storage managed-zones create cellblockhtml-zone-name --description="" --dns-name="cellblockhtml.org." --visibility="public" --dnssec-state="off"
+
+GET https://dns.googleapis.com/dns/v1/projects/atea-storage/managedZones/cellblockhtml-zone-name
+{
+  "cloudLoggingConfig": {
+    "enableLogging": false
+  },
+  "creationTime": "2024-01-26T01:16:48.494Z",
+  "description": "",
+  "dnsName": "cellblockhtml.org.",
+  "fingerprint": "22c472c7f1624dc30000018d435741ee",
+  "id": 2505253495798648259,
+  "location": "global",
+  "name": "cellblockhtml-zone-name",
+  "nameServers": [
+    "ns-cloud-b1.googledomains.com.",
+    "ns-cloud-b2.googledomains.com.",
+    "ns-cloud-b3.googledomains.com.",
+    "ns-cloud-b4.googledomains.com."
+  ],
+  "visibility": "public"
+}
+
+
+From:
+    https://console.cloud.google.com/net-services/dns/zones/cellblockhtml-zone-name/details?project=atea-storage
+
+Determine the IP numbers for the NS [Presumably, NameServer(s)]
+
+  ns-cloud-b1.googledomains.com
+  ns-cloud-b2.googledomains.com
+  ns-cloud-b3.googledomains.com
+  ns-cloud-b4.googledomains.com
+
+
+So:
+
+    $ dig  ns-cloud-b1.googledomains.com +short
+    216.239.32.107
+    $ dig  ns-cloud-b2.googledomains.com +short
+    216.239.34.107
+    $ dig  ns-cloud-b3.googledomains.com +short
+    216.239.36.107
+    $ dig  ns-cloud-b4.googledomains.com +short
+    216.239.38.107
+
+Verify things match:
+
+  dig -t NS cellblockhtml.org
+
+
+
+Add an A-record
+
+gcloud dns --project=atea-storage record-sets create cellblockhtml.org. --zone="cellblockhtml-zone-name" --type="A" --ttl="300" --rrdatas="35.213.231.194"
+
+i.e. the IP NIC assigned to gcloud-ansible
+
+
+====
+
+Name Server 1	ns.freeparking.co.nz		27.124.125.244,2a00:fd80:aaaa:ffff::ccdd:3	
+Name Server 2	ns2.freeparking.co.nz		27.124.125.245,2a00:fd80:aaaa:ffff::ccdd:4
+
+
+ dig -t NS cellblockhtml.org
+
+; <<>> DiG 9.18.12-0ubuntu0.22.04.3-Ubuntu <<>> -t NS cellblockhtml.org
+;; global options: +cmd
+;; Got answer:
+;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 26875
+;; flags: qr rd ra; QUERY: 1, ANSWER: 2, AUTHORITY: 0, ADDITIONAL: 1
+
+;; OPT PSEUDOSECTION:
+; EDNS: version: 0, flags:; udp: 65494
+;; QUESTION SECTION:
+;cellblockhtml.org.		IN	NS
+
+;; ANSWER SECTION:
+cellblockhtml.org.	3600	IN	NS	ns.freeparking.co.nz.
+cellblockhtml.org.	3600	IN	NS	ns2.freeparking.co.nz.
+
+;; Query time: 36 msec
+;; SERVER: 127.0.0.53#53(127.0.0.53) (UDP)
+;; WHEN: Fri Jan 26 03:45:28 UTC 2024
+;; MSG SIZE  rcvd: 98
+
Index: gs3-extensions/vm-manager/trunk/src/append-dns-zone/_local_config.bash
===================================================================
--- gs3-extensions/vm-manager/trunk/src/append-dns-zone/_local_config.bash	(revision 38649)
+++ gs3-extensions/vm-manager/trunk/src/append-dns-zone/_local_config.bash	(revision 38649)
@@ -0,0 +1,8 @@
+
+if [ "x$TL_DOMAIN" = "x" ] ; then
+    
+    TL_DOMAIN=atea.space
+
+    zone_name=$(echo $TL_DOMAIN | sed 's/\./-/g')--zone
+    dns_name=${TL_DOMAIN}.
+fi
Index: gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-create-zone.sh
===================================================================
--- gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-create-zone.sh	(revision 38649)
+++ gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-create-zone.sh	(revision 38649)
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+. ./_local_config.bash
+
+
+gcloud dns \
+       --project=atea-storage \
+       managed-zones create $zone_name \
+       --description="$zone_name created by Greenstone3's VM Manager Extension" \
+       --dns-name="$dns_name" \
+       --visibility="public" \
+       --dnssec-state="off"
Index: gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-describe-zone.sh
===================================================================
--- gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-describe-zone.sh	(revision 38649)
+++ gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-describe-zone.sh	(revision 38649)
@@ -0,0 +1,7 @@
+#!/bin/bash
+
+. ./_local_config.bash
+
+gcloud dns \
+       --project=atea-storage \
+       managed-zones describe $zone_name $@
Index: gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-list-ns.sh
===================================================================
--- gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-list-ns.sh	(revision 38649)
+++ gs3-extensions/vm-manager/trunk/src/append-dns-zone/gcloud-dns-list-ns.sh	(revision 38649)
@@ -0,0 +1,14 @@
+#!/bin/bash
+
+. ./_local_config.bash
+
+ns_servers=$(./gcloud-dns-describe-zone.sh --format='value(nameServers)')
+
+
+IFS_store=$IFS
+IFS=';'
+for ns_server in $ns_servers ; do
+    echo $ns_server
+    dig $ns_server +short
+done
+IFS=$IFS_store
