From b6c117d5db2c73e390a2d7d8a18ddfdbf27af263 Mon Sep 17 00:00:00 2001 From: Julia Longtin Date: Tue, 30 Jan 2024 16:43:06 +0000 Subject: [PATCH] add gandi instructions --- .../single_hetzner_machine_installation.md | 48 +++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/offline/single_hetzner_machine_installation.md b/offline/single_hetzner_machine_installation.md index 18e9ef3de..06fbfc41a 100644 --- a/offline/single_hetzner_machine_installation.md +++ b/offline/single_hetzner_machine_installation.md @@ -560,6 +560,54 @@ List VMs: sudo virsh list --all ``` +### To get a domain for WIAB experimentation + +using: https://github.com/Gandi/gandi.cli + +``` +sudo apt install pipx +pipx install gandi-cli +pipx ensurepath +(logout, log back in) +``` + +``` +gandi setup +``` +the API key from the gandi web interface should be entered in the "Api key (rest)" and "Api key (xmlrpc)". + +If you need to nuke it, it's stored in ~/.config/gandi/config.yaml + +Once this is set up properly, you should be able to "gandi dns list ", for domains you own with gandi. + +I then built the following shell script. + +domains-kittensonfire.sh +``` +#!/bin/bash +domains="nginz-https nginz-ssl webapp assets account teams federator" +sft_domains="sftd" +ipaddr=65.109.105.243 + +# one of the staging SFT servers. +sft_ipaddr=168.119.168.239 + +# update the domain itsself +gandi dns update kittensonfire.com -ttl 600 @ A $ipaddr + +# update subrecords of kittensonfire.com +for each in $domains; do + gandi dns update kittensonfire.com --ttl 600 $each A $ipaddr + sleep 5 +done + +# separately update the SFT subrecords of kittensonfire.com +for each in $sft_domains; do + gandi dns update kittensonfire.com --ttl 600 $each A $sft_ipaddr + sleep 5 +done +``` + ### From this point: switch to docs_ubuntu_22.04.md.