nginxproxymanager-v5.sh 15 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535
  1. #!/usr/bin/env bash
  2. # Copyright (c) 2021-2023 tteck
  3. # Author: tteck (tteckster)
  4. # License: MIT
  5. # https://github.com/tteck/Proxmox/raw/main/LICENSE
  6. function header_info {
  7. clear
  8. cat <<"EOF"
  9. _ __ _ ____ __ ___
  10. / | / /___ _(_)___ _ __ / __ \_________v5_ ____ __ / |/ /___ _____ ____ _____ ____ _____
  11. / |/ / __ / / __ \| |/_/ / /_/ / ___/ __ \| |/_/ / / / / /|_/ / __ / __ \/ __ / __ / _ \/ ___/
  12. / /| / /_/ / / / / /> < / ____/ / / /_/ /> </ /_/ / / / / / /_/ / / / / /_/ / /_/ / __/ /
  13. /_/ |_/\__, /_/_/ /_/_/|_| /_/ /_/ \____/_/|_|\__, / /_/ /_/\__,_/_/ /_/\__,_/\__, /\___/_/
  14. /____/ /____/ /____/
  15. EOF
  16. }
  17. header_info
  18. echo -e "Loading..."
  19. APP="Nginx Proxy Manager"
  20. var_disk="4"
  21. var_cpu="1"
  22. var_ram="1024"
  23. var_os="debian"
  24. var_version="11"
  25. NSAPP=$(echo ${APP,,} | tr -d ' ')
  26. var_install="${NSAPP}-v5-install"
  27. timezone=$(cat /etc/timezone)
  28. INTEGER='^[0-9]+([.][0-9]+)?$'
  29. YW=$(echo "\033[33m")
  30. BL=$(echo "\033[36m")
  31. RD=$(echo "\033[01;31m")
  32. BGN=$(echo "\033[4;92m")
  33. GN=$(echo "\033[1;92m")
  34. DGN=$(echo "\033[32m")
  35. CL=$(echo "\033[m")
  36. BFR="\\r\\033[K"
  37. HOLD="-"
  38. CM="${GN}✓${CL}"
  39. CROSS="${RD}✗${CL}"
  40. set -Eeuo pipefail
  41. trap 'error_handler $LINENO "$BASH_COMMAND"' ERR
  42. function error_handler() {
  43. local exit_code="$?"
  44. local line_number="$1"
  45. local command="$2"
  46. local error_message="${RD}[ERROR]${CL} in line ${RD}$line_number${CL}: exit code ${RD}$exit_code${CL}: while executing command ${YW}$command${CL}"
  47. echo -e "\n$error_message\n"
  48. }
  49. function msg_info() {
  50. local msg="$1"
  51. echo -ne " ${HOLD} ${YW}${msg}..."
  52. }
  53. function msg_ok() {
  54. local msg="$1"
  55. echo -e "${BFR} ${CM} ${GN}${msg}${CL}"
  56. }
  57. function msg_error() {
  58. local msg="$1"
  59. echo -e "${BFR} ${CROSS} ${RD}${msg}${CL}"
  60. }
  61. function PVE_CHECK() {
  62. if [ $(pveversion | grep -c "pve-manager/7\.[0-9]") -eq 0 ]; then
  63. echo -e "${CROSS} This version of Proxmox Virtual Environment is not supported"
  64. echo -e "Requires PVE Version 7.0 or higher"
  65. echo -e "Exiting..."
  66. sleep 2
  67. exit
  68. fi
  69. }
  70. function ARCH_CHECK() {
  71. if [ "$(dpkg --print-architecture)" != "amd64" ]; then
  72. echo -e "\n ${CROSS} This script will not work with PiMox! \n"
  73. echo -e "Exiting..."
  74. sleep 2
  75. exit
  76. fi
  77. }
  78. function default_settings() {
  79. echo -e "${DGN}Using Container Type: ${BGN}Unprivileged${CL} ${RD}NO DEVICE PASSTHROUGH${CL}"
  80. CT_TYPE="1"
  81. echo -e "${DGN}Using Root Password: ${BGN}Automatic Login${CL}"
  82. PW=""
  83. echo -e "${DGN}Using Container ID: ${BGN}$NEXTID${CL}"
  84. CT_ID=$NEXTID
  85. echo -e "${DGN}Using Hostname: ${BGN}$NSAPP${CL}"
  86. HN=$NSAPP
  87. echo -e "${DGN}Using Disk Size: ${BGN}$var_disk${CL}${DGN}GB${CL}"
  88. DISK_SIZE="$var_disk"
  89. echo -e "${DGN}Allocated Cores ${BGN}$var_cpu${CL}"
  90. CORE_COUNT="$var_cpu"
  91. echo -e "${DGN}Allocated Ram ${BGN}$var_ram${CL}"
  92. RAM_SIZE="$var_ram"
  93. echo -e "${DGN}Using Bridge: ${BGN}vmbr0${CL}"
  94. BRG="vmbr0"
  95. echo -e "${DGN}Using Static IP Address: ${BGN}dhcp${CL}"
  96. NET=dhcp
  97. echo -e "${DGN}Using Gateway Address: ${BGN}Default${CL}"
  98. GATE=""
  99. echo -e "${DGN}Disable IPv6: ${BGN}No${CL}"
  100. DISABLEIP6="no"
  101. echo -e "${DGN}Using Interface MTU Size: ${BGN}Default${CL}"
  102. MTU=""
  103. echo -e "${DGN}Using DNS Search Domain: ${BGN}Host${CL}"
  104. SD=""
  105. echo -e "${DGN}Using DNS Server Address: ${BGN}Host${CL}"
  106. NS=""
  107. echo -e "${DGN}Using MAC Address: ${BGN}Default${CL}"
  108. MAC=""
  109. echo -e "${DGN}Using VLAN Tag: ${BGN}Default${CL}"
  110. VLAN=""
  111. echo -e "${DGN}Enable Root SSH Access: ${BGN}No${CL}"
  112. SSH="no"
  113. echo -e "${DGN}Enable Verbose Mode: ${BGN}No${CL}"
  114. VERB="no"
  115. echo -e "${BL}Creating a ${APP} LXC using the above default settings${CL}"
  116. }
  117. function exit-script() {
  118. clear
  119. echo -e "⚠ User exited script \n"
  120. exit
  121. }
  122. function advanced_settings() {
  123. if CT_TYPE=$(whiptail --title "CONTAINER TYPE" --radiolist "Choose Type" 10 58 2 \
  124. "1" "Unprivileged" ON \
  125. "0" "Privileged" OFF \
  126. 3>&1 1>&2 2>&3); then
  127. echo -e "${DGN}Using Container Type: ${BGN}$CT_TYPE${CL}"
  128. else
  129. exit-script
  130. fi
  131. if PW1=$(whiptail --inputbox "\nSet Root Password (needed for root ssh access)" 9 58 --title "PASSWORD(leave blank for automatic login)" 3>&1 1>&2 2>&3); then
  132. if [ -z $PW1 ]; then
  133. PW1="Automatic Login"
  134. PW=" "
  135. else
  136. PW="-password $PW1"
  137. fi
  138. echo -e "${DGN}Using Root Password: ${BGN}$PW1${CL}"
  139. else
  140. exit-script
  141. fi
  142. if CT_ID=$(whiptail --inputbox "Set Container ID" 8 58 $NEXTID --title "CONTAINER ID" 3>&1 1>&2 2>&3); then
  143. if [ -z "$CT_ID" ]; then
  144. CT_ID="$NEXTID"
  145. echo -e "${DGN}Using Container ID: ${BGN}$CT_ID${CL}"
  146. else
  147. echo -e "${DGN}Container ID: ${BGN}$CT_ID${CL}"
  148. fi
  149. else
  150. exit
  151. fi
  152. if CT_NAME=$(whiptail --inputbox "Set Hostname" 8 58 $NSAPP --title "HOSTNAME" 3>&1 1>&2 2>&3); then
  153. if [ -z "$CT_NAME" ]; then
  154. HN="$NSAPP"
  155. else
  156. HN=$(echo ${CT_NAME,,} | tr -d ' ')
  157. fi
  158. echo -e "${DGN}Using Hostname: ${BGN}$HN${CL}"
  159. else
  160. exit-script
  161. fi
  162. if DISK_SIZE=$(whiptail --inputbox "Set Disk Size in GB" 8 58 $var_disk --title "DISK SIZE" 3>&1 1>&2 2>&3); then
  163. if [ -z "$DISK_SIZE" ]; then
  164. DISK_SIZE="$var_disk"
  165. echo -e "${DGN}Using Disk Size: ${BGN}$DISK_SIZE${CL}"
  166. else
  167. if ! [[ $DISK_SIZE =~ $INTEGER ]]; then
  168. echo -e "${RD}⚠ DISK SIZE MUST BE AN INTEGER NUMBER!${CL}"
  169. advanced_settings
  170. fi
  171. echo -e "${DGN}Using Disk Size: ${BGN}$DISK_SIZE${CL}"
  172. fi
  173. else
  174. exit-script
  175. fi
  176. if CORE_COUNT=$(whiptail --inputbox "Allocate CPU Cores" 8 58 $var_cpu --title "CORE COUNT" 3>&1 1>&2 2>&3); then
  177. if [ -z "$CORE_COUNT" ]; then
  178. CORE_COUNT="$var_cpu"
  179. echo -e "${DGN}Allocated Cores: ${BGN}$CORE_COUNT${CL}"
  180. else
  181. echo -e "${DGN}Allocated Cores: ${BGN}$CORE_COUNT${CL}"
  182. fi
  183. else
  184. exit-script
  185. fi
  186. if RAM_SIZE=$(whiptail --inputbox "Allocate RAM in MiB" 8 58 $var_ram --title "RAM" 3>&1 1>&2 2>&3); then
  187. if [ -z "$RAM_SIZE" ]; then
  188. RAM_SIZE="$var_ram"
  189. echo -e "${DGN}Allocated RAM: ${BGN}$RAM_SIZE${CL}"
  190. else
  191. echo -e "${DGN}Allocated RAM: ${BGN}$RAM_SIZE${CL}"
  192. fi
  193. else
  194. exit-script
  195. fi
  196. if BRG=$(whiptail --inputbox "Set a Bridge" 8 58 vmbr0 --title "BRIDGE" 3>&1 1>&2 2>&3); then
  197. if [ -z "$BRG" ]; then
  198. BRG="vmbr0"
  199. echo -e "${DGN}Using Bridge: ${BGN}$BRG${CL}"
  200. else
  201. echo -e "${DGN}Using Bridge: ${BGN}$BRG${CL}"
  202. fi
  203. else
  204. exit-script
  205. fi
  206. if NET=$(whiptail --inputbox "Set a Static IPv4 CIDR Address(/24)" 8 58 dhcp --title "IP ADDRESS" 3>&1 1>&2 2>&3); then
  207. if [ -z $NET ]; then
  208. NET="dhcp"
  209. echo -e "${DGN}Using IP Address: ${BGN}$NET${CL}"
  210. else
  211. echo -e "${DGN}Using IP Address: ${BGN}$NET${CL}"
  212. fi
  213. else
  214. exit-script
  215. fi
  216. if GATE1=$(whiptail --inputbox "Set a Gateway IP (mandatory if Static IP was used)" 8 58 --title "GATEWAY IP" 3>&1 1>&2 2>&3); then
  217. if [ -z $GATE1 ]; then
  218. GATE1="Default"
  219. GATE=""
  220. else
  221. GATE=",gw=$GATE1"
  222. fi
  223. echo -e "${DGN}Using Gateway IP Address: ${BGN}$GATE1${CL}"
  224. else
  225. exit-script
  226. fi
  227. if (whiptail --defaultno --title "IPv6" --yesno "Disable IPv6?" 10 58); then
  228. DISABLEIP6="yes"
  229. else
  230. DISABLEIP6="no"
  231. fi
  232. echo -e "${DGN}Disable IPv6: ${BGN}$DISABLEIP6${CL}"
  233. if MTU1=$(whiptail --inputbox "Set Interface MTU Size (leave blank for default)" 8 58 --title "MTU SIZE" 3>&1 1>&2 2>&3); then
  234. if [ -z $MTU1 ]; then
  235. MTU1="Default"
  236. MTU=""
  237. else
  238. MTU=",mtu=$MTU1"
  239. fi
  240. echo -e "${DGN}Using Interface MTU Size: ${BGN}$MTU1${CL}"
  241. else
  242. exit-script
  243. fi
  244. if SD=$(whiptail --inputbox "Set a DNS Search Domain (leave blank for HOST)" 8 58 --title "DNS Search Domain" 3>&1 1>&2 2>&3); then
  245. if [ -z $SD ]; then
  246. SX=Host
  247. SD=""
  248. else
  249. SX=$SD
  250. SD="-searchdomain=$SD"
  251. fi
  252. echo -e "${DGN}Using DNS Search Domain: ${BGN}$SX${CL}"
  253. else
  254. exit-script
  255. fi
  256. if NX=$(whiptail --inputbox "Set a DNS Server IP (leave blank for HOST)" 8 58 --title "DNS SERVER IP" 3>&1 1>&2 2>&3); then
  257. if [ -z $NX ]; then
  258. NX=Host
  259. NS=""
  260. else
  261. NS="-nameserver=$NX"
  262. fi
  263. echo -e "${DGN}Using DNS Server IP Address: ${BGN}$NX${CL}"
  264. else
  265. exit-script
  266. fi
  267. if MAC1=$(whiptail --inputbox "Set a MAC Address(leave blank for default)" 8 58 --title "MAC ADDRESS" 3>&1 1>&2 2>&3); then
  268. if [ -z $MAC1 ]; then
  269. MAC1="Default"
  270. MAC=""
  271. else
  272. MAC=",hwaddr=$MAC1"
  273. echo -e "${DGN}Using MAC Address: ${BGN}$MAC1${CL}"
  274. fi
  275. else
  276. exit-script
  277. fi
  278. if VLAN1=$(whiptail --inputbox "Set a Vlan(leave blank for default)" 8 58 --title "VLAN" 3>&1 1>&2 2>&3); then
  279. if [ -z $VLAN1 ]; then
  280. VLAN1="Default"
  281. VLAN=""
  282. else
  283. VLAN=",tag=$VLAN1"
  284. fi
  285. echo -e "${DGN}Using Vlan: ${BGN}$VLAN1${CL}"
  286. else
  287. exit-script
  288. fi
  289. if (whiptail --defaultno --title "SSH ACCESS" --yesno "Enable Root SSH Access?" 10 58); then
  290. SSH="yes"
  291. else
  292. SSH="no"
  293. fi
  294. echo -e "${DGN}Enable Root SSH Access: ${BGN}$SSH${CL}"
  295. if (whiptail --defaultno --title "VERBOSE MODE" --yesno "Enable Verbose Mode?" 10 58); then
  296. VERB="yes"
  297. else
  298. VERB="no"
  299. fi
  300. echo -e "${DGN}Enable Verbose Mode: ${BGN}$VERB${CL}"
  301. if (whiptail --title "ADVANCED SETTINGS COMPLETE" --yesno "Ready to create ${APP} LXC?" 10 58); then
  302. echo -e "${RD}Creating a ${APP} LXC using the above advanced settings${CL}"
  303. else
  304. clear
  305. header_info
  306. echo -e "${RD}Using Advanced Settings${CL}"
  307. advanced_settings
  308. fi
  309. }
  310. function install_script() {
  311. ARCH_CHECK
  312. PVE_CHECK
  313. NEXTID=$(pvesh get /cluster/nextid)
  314. header_info
  315. if (whiptail --title "SETTINGS" --yesno "Use Default Settings?" --no-button Advanced 10 58); then
  316. header_info
  317. echo -e "${BL}Using Default Settings${CL}"
  318. default_settings
  319. else
  320. header_info
  321. echo -e "${RD}Using Advanced Settings${CL}"
  322. advanced_settings
  323. fi
  324. }
  325. function update_script() {
  326. header_info
  327. RELEASE=$(curl -s https://api.github.com/repos/NginxProxyManager/nginx-proxy-manager/releases/latest |
  328. grep "tag_name" |
  329. awk '{print substr($2, 3, length($2)-4) }')
  330. msg_info "Stopping Services"
  331. systemctl stop openresty
  332. systemctl stop npm
  333. msg_ok "Stopped Services"
  334. msg_info "Cleaning Old Files"
  335. rm -rf /app \
  336. /var/www/html \
  337. /etc/nginx \
  338. /var/log/nginx \
  339. /var/lib/nginx \
  340. /var/cache/nginx &>/dev/null
  341. msg_ok "Cleaned Old Files"
  342. msg_info "Downloading NPM v${RELEASE}"
  343. wget -q https://codeload.github.com/NginxProxyManager/nginx-proxy-manager/tar.gz/v${RELEASE} -O - | tar -xz &>/dev/null
  344. cd nginx-proxy-manager-${RELEASE}
  345. msg_ok "Downloaded NPM v${RELEASE}"
  346. msg_info "Setting up Enviroment"
  347. ln -sf /usr/bin/python3 /usr/bin/python
  348. ln -sf /usr/bin/certbot /opt/certbot/bin/certbot
  349. ln -sf /usr/local/openresty/nginx/sbin/nginx /usr/sbin/nginx
  350. ln -sf /usr/local/openresty/nginx/ /etc/nginx
  351. sed -i "s+0.0.0+${RELEASE}+g" backend/package.json
  352. sed -i "s+0.0.0+${RELEASE}+g" frontend/package.json
  353. sed -i 's+^daemon+#daemon+g' docker/rootfs/etc/nginx/nginx.conf
  354. NGINX_CONFS=$(find "$(pwd)" -type f -name "*.conf")
  355. for NGINX_CONF in $NGINX_CONFS; do
  356. sed -i 's+include conf.d+include /etc/nginx/conf.d+g' "$NGINX_CONF"
  357. done
  358. mkdir -p /var/www/html /etc/nginx/logs
  359. cp -r docker/rootfs/var/www/html/* /var/www/html/
  360. cp -r docker/rootfs/etc/nginx/* /etc/nginx/
  361. cp docker/rootfs/etc/letsencrypt.ini /etc/letsencrypt.ini
  362. cp docker/rootfs/etc/logrotate.d/nginx-proxy-manager /etc/logrotate.d/nginx-proxy-manager
  363. ln -sf /etc/nginx/nginx.conf /etc/nginx/conf/nginx.conf
  364. rm -f /etc/nginx/conf.d/dev.conf
  365. mkdir -p /tmp/nginx/body \
  366. /run/nginx \
  367. /data/nginx \
  368. /data/custom_ssl \
  369. /data/logs \
  370. /data/access \
  371. /data/nginx/default_host \
  372. /data/nginx/default_www \
  373. /data/nginx/proxy_host \
  374. /data/nginx/redirection_host \
  375. /data/nginx/stream \
  376. /data/nginx/dead_host \
  377. /data/nginx/temp \
  378. /var/lib/nginx/cache/public \
  379. /var/lib/nginx/cache/private \
  380. /var/cache/nginx/proxy_temp
  381. chmod -R 777 /var/cache/nginx
  382. chown root /tmp/nginx
  383. echo resolver "$(awk 'BEGIN{ORS=" "} $1=="nameserver" {print ($2 ~ ":")? "["$2"]": $2}' /etc/resolv.conf);" >/etc/nginx/conf.d/include/resolvers.conf
  384. if [ ! -f /data/nginx/dummycert.pem ] || [ ! -f /data/nginx/dummykey.pem ]; then
  385. echo -e "${CHECKMARK} \e[1;92m Generating dummy SSL Certificate... \e[0m"
  386. openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 -subj "/O=Nginx Proxy Manager/OU=Dummy Certificate/CN=localhost" -keyout /data/nginx/dummykey.pem -out /data/nginx/dummycert.pem &>/dev/null
  387. fi
  388. mkdir -p /app/global /app/frontend/images
  389. cp -r backend/* /app
  390. cp -r global/* /app/global
  391. msg_ok "Setup Enviroment"
  392. msg_info "Building Frontend"
  393. cd ./frontend
  394. export NODE_ENV=development
  395. yarn install --network-timeout=30000 &>/dev/null
  396. yarn build &>/dev/null
  397. cp -r dist/* /app/frontend
  398. cp -r app-images/* /app/frontend/images
  399. msg_ok "Built Frontend"
  400. msg_info "Initializing Backend"
  401. rm -rf /app/config/default.json &>/dev/null
  402. if [ ! -f /app/config/production.json ]; then
  403. cat <<'EOF' >/app/config/production.json
  404. {
  405. "database": {
  406. "engine": "knex-native",
  407. "knex": {
  408. "client": "sqlite3",
  409. "connection": {
  410. "filename": "/data/database.sqlite"
  411. }
  412. }
  413. }
  414. }
  415. EOF
  416. fi
  417. cd /app
  418. export NODE_ENV=development
  419. yarn install --network-timeout=30000 &>/dev/null
  420. msg_ok "Initialized Backend"
  421. msg_info "Starting Services"
  422. systemctl enable npm &>/dev/null
  423. systemctl start openresty
  424. systemctl start npm
  425. msg_ok "Started Services"
  426. msg_info "Cleaning up"
  427. rm -rf ~/nginx-proxy-manager-*
  428. msg_ok "Cleaned"
  429. msg_ok "Update Successfull"
  430. exit
  431. }
  432. if command -v pveversion >/dev/null 2>&1; then
  433. if ! (whiptail --title "${APP} LXC" --yesno "This will create a New ${APP} LXC. Proceed?" 10 58); then
  434. clear
  435. echo -e "⚠ User exited script \n"
  436. exit
  437. fi
  438. install_script
  439. fi
  440. if ! command -v pveversion >/dev/null 2>&1 && [[ ! -f /lib/systemd/system/npm.service ]]; then
  441. msg_error "No ${APP} Installation Found!"
  442. exit
  443. fi
  444. if ! command -v pveversion >/dev/null 2>&1; then
  445. if ! (whiptail --title "${APP} LXC UPDATE" --yesno "This will update ${APP} LXC. Proceed?" 10 58); then
  446. clear
  447. echo -e "⚠ User exited script \n"
  448. exit
  449. fi
  450. update_script
  451. fi
  452. if [ "$VERB" == "yes" ]; then set -x; fi
  453. if [ "$CT_TYPE" == "1" ]; then
  454. FEATURES="nesting=1,keyctl=1"
  455. else
  456. FEATURES="nesting=1"
  457. fi
  458. TEMP_DIR=$(mktemp -d)
  459. pushd $TEMP_DIR >/dev/null
  460. export tz=$timezone
  461. export DISABLEIPV6=$DISABLEIP6
  462. export APPLICATION=$APP
  463. export VERBOSE=$VERB
  464. export SSH_ROOT=${SSH}
  465. export CTID=$CT_ID
  466. export PCT_OSTYPE=$var_os
  467. export PCT_OSVERSION=$var_version
  468. export PCT_DISK_SIZE=$DISK_SIZE
  469. export PCT_OPTIONS="
  470. -features $FEATURES
  471. -hostname $HN
  472. $SD
  473. $NS
  474. -net0 name=eth0,bridge=$BRG$MAC,ip=$NET$GATE$VLAN$MTU
  475. -onboot 1
  476. -cores $CORE_COUNT
  477. -memory $RAM_SIZE
  478. -unprivileged $CT_TYPE
  479. $PW
  480. "
  481. bash -c "$(wget -qLO - https://raw.githubusercontent.com/tteck/Proxmox/main/ct/create_lxc.sh)" || exit
  482. msg_info "Starting LXC Container"
  483. pct start $CTID
  484. msg_ok "Started LXC Container"
  485. lxc-attach -n $CTID -- bash -c "$(wget -qLO - https://raw.githubusercontent.com/tteck/Proxmox/main/install/$var_install.sh)" || exit
  486. IP=$(pct exec $CTID ip a s dev eth0 | awk '/inet / {print $2}' | cut -d/ -f1)
  487. pct set $CTID -description "# ${APP} LXC
  488. ### https://tteck.github.io/Proxmox/
  489. <a href='https://ko-fi.com/D1D7EP4GF'><img src='https://img.shields.io/badge/☕-Buy me a coffee-red' /></a>"
  490. msg_ok "Completed Successfully!\n"
  491. echo -e "${APP} should be reachable by going to the following URL.
  492. ${BL}http://${IP}:81${CL} \n"