[convertdomain] Add option to skip DNS operations
Signed-off-by: Bernhard Rosenkränzer <bero@federated.computer>
This commit is contained in:
parent
7142d56d20
commit
fd4223e904
@ -55,7 +55,7 @@ check_gluerecords() {
|
||||
do_serviceprep_dns() {
|
||||
# Create DNS records for newdomain
|
||||
docker exec pdns pdnsutil create-zone $DOMAIN_NEW
|
||||
docker exec pdns pdnsutil set-kind $DOMAIN_NEW native
|
||||
docker exec pdns pdnsutil set-kind $DOMAIN_NEW primary
|
||||
docker exec pdns pdnsutil set-meta $DOMAIN_NEW SOA-EDIT-API DEFAULT
|
||||
|
||||
for i in ns1 powerdns traefik mail www computer panel nextcloud collabora jitsi matrix element listmonk vaultwarden vpn wireguard baserow gitea blog documentation podcasts castopod caddy wordpress bookstack freescout msp espocrm dashboard plane calcom; do
|
||||
@ -890,6 +890,12 @@ usage() {
|
||||
exit 2
|
||||
}
|
||||
|
||||
DNS_DONE=false
|
||||
if [ "$1" = "-d" -o "$1" = "--dns-done" ]; then
|
||||
DNS_DONE=true
|
||||
shift
|
||||
fi
|
||||
|
||||
[ $# != 2 ] && usage
|
||||
DOMAIN_NEW=$1
|
||||
ORG_NEW=$2
|
||||
@ -918,9 +924,11 @@ MYSQL_ROOTPASSWORD=`cat /federated/apps/pdnsmysql/.env | grep MYSQL_ROOT_PASSWOR
|
||||
echo -ne "\n\nConverting Federated Core $DOMAIN to $DOMAIN_NEW.\n\n"
|
||||
|
||||
# Key initial steps
|
||||
check_gluerecords
|
||||
if ! $DNS_DONE; then
|
||||
check_gluerecords
|
||||
#get_installedapps
|
||||
do_serviceprep_dns
|
||||
do_serviceprep_dns
|
||||
fi
|
||||
do_serviceprep_ldap
|
||||
|
||||
# Stop all services
|
||||
|
Loading…
x
Reference in New Issue
Block a user