summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrew Cady <d@jerkface.net>2020-09-15 13:32:00 -0400
committerAndrew Cady <d@jerkface.net>2020-09-15 13:32:00 -0400
commit24bbf1df3369e90ba66b37f8389d2e42bc777d26 (patch)
tree586855623d5ef87c38c6453bd62c24929109a6cb
parent83219573ed12f3ec6abe85f9481dacd1363bb008 (diff)
eliminate duplication
-rw-r--r--selfpublish.sh13
1 files changed, 7 insertions, 6 deletions
diff --git a/selfpublish.sh b/selfpublish.sh
index ffc7ad0..c97163f 100644
--- a/selfpublish.sh
+++ b/selfpublish.sh
@@ -537,17 +537,18 @@ case "$DOMAIN" in
537 exit 1 ;; 537 exit 1 ;;
538esac 538esac
539 539
540if ! check_tls "$DOMAIN" || force 540check_tls "$DOMAIN"
541then 541tls_result=$?
542 install_apache_vhost
543 configure_apache_vhost
544 542
543install_apache_vhost
544configure_apache_vhost
545
546if [ $tls_result != 0 ] || force
547then
545 systemctl restart apache2 548 systemctl restart apache2
546 wait_for_certificate_issuance "$DOMAIN" 549 wait_for_certificate_issuance "$DOMAIN"
547 systemctl reload apache2 || systemctl restart apache2 550 systemctl reload apache2 || systemctl restart apache2
548else 551else
549 install_apache_vhost
550 configure_apache_vhost
551 systemctl reload apache2 || systemctl restart apache2 552 systemctl reload apache2 || systemctl restart apache2
552fi 553fi
553 554