From 6ec7228db4a62c3cb71a3a1501cc5fe600a4d4b5 Mon Sep 17 00:00:00 2001 From: DarkCat09 Date: Wed, 19 Feb 2025 14:10:57 +0400 Subject: [PATCH] feat: ask for installation method --- run.sh | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) diff --git a/run.sh b/run.sh index 3cf3352..78bba89 100755 --- a/run.sh +++ b/run.sh @@ -8,7 +8,23 @@ then # check if stdin (fd 0) is assigned to a tty [ ! -t 0 ] && echo "Not a TTY! Exiting" && exit 1 - /venv/bin/certbot certonly --nginx + echo "Choose installation method:" + echo " 1. get certs for hosts specified in nginx.conf" + echo " and automatically edit the config (default)" + echo " 2. get certs for hosts, do not edit the config" + echo " 3. just launch shell, i'll do it myself" + read n + + if [ "$n" = 3 ] + then + /bin/ash -i + elif [ "$n" = 2 ] + then + /venv/bin/certbot certonly --nginx + else + /venv/bin/certbot --nginx + fi + exit $? fi