add Docker LXCs to build.func & tweaks

pull/1251/head
tteckster 2023-03-23 07:07:49 -04:00 committed by GitHub
parent dab04f23a3
commit 8500e495b0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
37 changed files with 34 additions and 40 deletions

View File

@ -1,5 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/docker.func) source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build.func)
# Copyright (c) 2021-2023 tteck # Copyright (c) 2021-2023 tteck
# Author: tteck (tteckster) # Author: tteck (tteckster)
# License: MIT # License: MIT

View File

@ -1,5 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/docker.func) source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build.func)
# Copyright (c) 2021-2023 tteck # Copyright (c) 2021-2023 tteck
# Author: tteck (tteckster) # Author: tteck (tteckster)
# License: MIT # License: MIT

View File

@ -46,6 +46,7 @@ function default_settings() {
MAC="" MAC=""
VLAN="" VLAN=""
SSH="no" SSH="no"
FUSE="no"
VERB="no" VERB="no"
echo_default echo_default
} }

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ ____ __
/ __ \____ _____ ___ _____/ /__ __________ ____ ____ __ __ / __ \____ _____ ___ _____/ /__ __________ ____ ____ __ __
/ /_/ / __ `/ __ \/ _ \/ ___/ / _ \/ ___/ ___/___/ __ \/ __ `/ |/_/ / /_/ / __ `/ __ \/ _ \/ ___/ / _ \/ ___/ ___/___/ __ \/ __ `/ |/_/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ ______ __________ ____ ____ _________ __ ___ ____ __ ______ __________ ____ ____ _________ __ ___
/ __ \/ / / / __ \/_ __/ __ \/ __ \/ __ \/ _/ ___// |/ / / __ \/ / / / __ \/_ __/ __ \/ __ \/ __ \/ _/ ___// |/ /
/ /_/ / /_/ / / / / / / / / / / /_/ / /_/ // / \__ \/ /|_/ / / /_/ / /_/ / / / / / / / / / / /_/ / /_/ // / \__ \/ /|_/ /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ ____ __ ______ __ ______ ____ ____ __ ______ __ ______
/ __ \/ _/ / / / / __ \/ / / ____/ / __ \/ _/ / / / / __ \/ / / ____/
/ /_/ // /___/ /_/ / / / / / / __/ / /_/ // /___/ /_/ / / / / / / __/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ __ ___ ___ _____ ____ __ __ ___ ___ _____
/ __ \/ /__ _ __ / |/ /__ ____/ (_)___ _ / ___/___ ______ _____ _____ / __ \/ /__ _ __ / |/ /__ ____/ (_)___ _ / ___/___ ______ _____ _____
/ /_/ / / _ \| |/_/ / /|_/ / _ \/ __ / / __ `/ \__ \/ _ \/ ___/ | / / _ \/ ___/ / /_/ / / _ \| |/_/ / /|_/ / _ \/ __ / / __ `/ \__ \/ _ \/ ___/ | / / _ \/ ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ ____ __
/ __ \____ ____/ /___ ___ ____ _____ / __ \____ ____/ /___ ___ ____ _____
/ /_/ / __ \/ __ / __ __ \/ __ / __ \ / /_/ / __ \/ __ / __ __ \/ __ / __ \

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ ____ __
/ __ \____ ____/ /___ ___ ____ _____ / __ \____ ____/ /___ ___ ____ _____
/ /_/ / __ \/ __ / __ `__ \/ __ `/ __ \ / /_/ / __ \/ __ / __ `__ \/ __ `/ __ \

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ _____ ____ __ ____ __ _____ ____ __
/ __ \____ _____/ /_____ _________ / ___// __ \ / / / __ \____ _____/ /_____ _________ / ___// __ \ / /
/ /_/ / __ \/ ___/ __/ __ / ___/ _ \\__ \/ / / / / / / /_/ / __ \/ ___/ __/ __ / ___/ _ \\__ \/ / / / / /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ __ ____ __ __
/ __ \_________ ____ ___ ___ / /_/ /_ ___ __ _______ / __ \_________ ____ ___ ___ / /_/ /_ ___ __ _______
/ /_/ / ___/ __ \/ __ __ \/ _ \/ __/ __ \/ _ \/ / / / ___/ / /_/ / ___/ __ \/ __ __ \/ _ \/ __/ __ \/ _ \/ / / / ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ ____ __
/ __ \_________ _ __/ /___ __________ / __ \_________ _ __/ /___ __________
/ /_/ / ___/ __ \ | /| / / / __ `/ ___/ ___/ / /_/ / ___/ __ \ | /| / / / __ `/ ___/ ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ ____ __
/ __ \____ _____/ /___ __________ / __ \____ _____/ /___ __________
/ /_/ / __ `/ __ / __ `/ ___/ ___/ / /_/ / __ `/ __ / __ `/ ___/ ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ ____ __
/ __ \___ ____ _____/ /___ __________ / __ \___ ____ _____/ /___ __________
/ /_/ / _ \/ __ `/ __ / __ `/ ___/ ___/ / /_/ / _ \/ __ `/ __ / __ `/ ___/ ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
____ __ __ _ ____ __ __ _
/ __ \____ _____/ /____ __ / / (_)___ __ ___ __ / __ \____ _____/ /____ __ / / (_)___ __ ___ __
/ /_/ / __ \/ ___/ //_/ / / / / / / / __ \/ / / / |/_/ / /_/ / __ \/ ___/ //_/ / / / / / / / __ \/ / / / |/_/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_____ ___ ____ __ __ _____ ___ ____ __ __
/ ___// | / __ )____ ____ / /_ ____/ / / ___// | / __ )____ ____ / /_ ____/ /
\__ \/ /| | / __ / __ \/_ / / __ \/ __ / \__ \/ /| | / __ / __ \/_ / / __ \/ __ /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_____ __ __ _____ __ __
/ ___/____________ ______ / /____ ____/ / / ___/____________ ______ / /____ ____/ /
\__ \/ ___/ ___/ / / / __ \/ __/ _ \/ __ / \__ \/ ___/ ___/ / / / __ \/ __/ _ \/ __ /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_____ __ _ __ _ _____ __ _ __ _
/ ___// /_ (_)___ ____ / /_ (_) / ___// /_ (_)___ ____ / /_ (_)
\__ \/ __ \/ / __ \/ __ \/ __ \/ / \__ \/ __ \/ / __ \/ __ \/ __ \/ /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_____ _____
/ ___/____ ____ ____ __________ / ___/____ ____ ____ __________
\__ \/ __ \/ __ \/ __ `/ ___/ ___/ \__ \/ __ \/ __ \/ __ `/ ___/ ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_____ __ __ _ _____ __ __ _
/ ___/__ ______ _____/ /_/ /_ (_)___ ____ _ / ___/__ ______ _____/ /_/ /_ (_)___ ____ _
\__ \/ / / / __ \/ ___/ __/ __ \/ / __ \/ __ `/ \__ \/ / / / __ \/ ___/ __/ __ \/ / __ \/ __ `/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
______ __ ______ __
/_ __/___/ /___ __________ /_ __/___/ /___ __________
/ / / __ / __ `/ ___/ ___/ / / / __ / __ `/ ___/ ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
______ __ _ __ _ ____ _ _______ ______ __ _ __ _ ____ _ _______
/_ __/__ _____/ /_ ____ (_) /_(_)_ ______ ___ / __ \/ | / / ___/ /_ __/__ _____/ /_ ____ (_) /_(_)_ ______ ___ / __ \/ | / / ___/
/ / / _ \/ ___/ __ \/ __ \/ / __/ / / / / __ __ \ / / / / |/ /\__ \ / / / _ \/ ___/ __ \/ __ \/ / __/ / / / / __ __ \ / / / / |/ /\__ \

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
______ _ _ ______ _ _
/_ __/________ _____ _________ ___ (_)_________(_)___ ____ /_ __/________ _____ _________ ___ (_)_________(_)___ ____
/ / / ___/ __ `/ __ \/ ___/ __ `__ \/ / ___/ ___/ / __ \/ __ \ / / / ___/ __ `/ __ \/ ___/ __ `__ \/ / ___/ ___/ / __ \/ __ \

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
______ _ ___ ______ _ ___
/_ __/____(_) (_)_ ______ ___ /_ __/____(_) (_)_ ______ ___
/ / / ___/ / / / / / / __ `__ \ / / / ___/ / / / / / / __ `__ \

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
__ ____ __ __ ____ __
/ / / / /_ __ ______ / /___ __ / / / / /_ __ ______ / /___ __
/ / / / __ \/ / / / __ \/ __/ / / / / / / / __ \/ / / / __ \/ __/ / / /

View File

@ -1,5 +1,5 @@
#!/usr/bin/env bash #!/usr/bin/env bash
source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/docker.func) source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build.func)
# Copyright (c) 2021-2023 tteck # Copyright (c) 2021-2023 tteck
# Author: tteck (tteckster) # Author: tteck (tteckster)
# License: MIT # License: MIT
@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/docke
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
__ __ __ __ __ __ __ __
/ / / /___ ___ / /_ ________ / / / / / /___ ___ / /_ ________ / /
/ / / / __ `__ \/ __ \/ ___/ _ \/ / / / / / __ `__ \/ __ \/ ___/ _ \/ /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
__ __ _ _____ __ __ _ _____
/ / / /__ (_) __(_) / / / /__ (_) __(_)
/ / / / __ \/ / /_/ / / / / / __ \/ / /_/ /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
__ __ __ _ __ __ __ __ __ _ __ __
/ / / /___ / /_(_)___ ___ ___ / //_/_ ______ ___ ____ _ / / / /___ / /_(_)___ ___ ___ / //_/_ ______ ___ ____ _
/ / / / __ \/ __/ / __ __ \/ _ \ / ,< / / / / __ __ \/ __ / / / / / __ \/ __/ / __ __ \/ _ \ / ,< / / / / __ __ \/ __ /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_ __ ____ _ __ __ _ __ ____ _ __ __
| | / /___ ___ __/ / /| | / /___ __________/ /__ ____ | | / /___ ___ __/ / /| | / /___ __________/ /__ ____
| | / / __ `/ / / / / __/ | /| / / __ `/ ___/ __ / _ \/ __ \ | | / / __ `/ / / / / __/ | /| / / __ `/ ___/ __ / _ \/ __ \

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_ ____ _ _ ____ _
| | / / /_ (_)________ ____ __________ | | / / /_ (_)________ ____ __________
| | /| / / __ \/ / ___/ __ \/ __ `/ ___/ ___/ | | /| / / __ \/ / ___/ __ \/ __ `/ ___/ ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_ ____ ______ ____ ________ ______ _ ____ ______ ____ ________ ______
| | / / / / / __ \/ __ \/ ____/ / / ____/ | | / / / / / __ \/ __ \/ ____/ / / ____/
| | /| / / /_/ / / / / / / / / __/ / / __/ | | /| / / /_/ / / / / / / / / __/ / / __/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_ ___ __ _ _ _ ___ __ _ _
| | / (_) /__(_) (_)____ | | / (_) /__(_) (_)____
| | /| / / / //_/ / / / ___/ | | /| / / / //_/ / / / ___/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_ ___ ______ __ _ ___ ______ __
| | / (_)_______ / ____/_ ______ __________/ / | | / (_)_______ / ____/_ ______ __________/ /
| | /| / / / ___/ _ \/ / __/ / / / __ `/ ___/ __ / | | /| / / / ___/ _ \/ / __/ / / / __ `/ ___/ __ /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
__ __ __ __ __ __ __ __ __ __
\ \/ /_ ______ ____ / / / /___ _____/ /_ \ \/ /_ ______ ____ / / / /___ _____/ /_
\ / / / / __ \/ __ \/ /_/ / __ \/ ___/ __/ \ / / / / __ \/ __ \/ /_/ / __ \/ ___/ __/

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_____ _ __ ___ __ _______ ____________ _____ _ __ ___ __ _______ ____________
/__ / (_)___ _/ /_ ___ ___ |__ \ / |/ / __ \/_ __/_ __/ /__ / (_)___ _/ /_ ___ ___ |__ \ / |/ / __ \/_ __/_ __/
/ / / / __ / __ \/ _ \/ _ \__/ // /|_/ / / / / / / / / / / / / __ / __ \/ _ \/ _ \__/ // /|_/ / / / / / / / /

View File

@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/build
function header_info { function header_info {
clear clear
cat <<"EOF" cat <<"EOF"
_____ _______ __ ______ _____ _______ __ ______
/__ /_ ______ __ _____ / / ___/ / / / / _/ /__ /_ ______ __ _____ / / ___/ / / / / _/
/ /| | /| / / __ `/ | / / _ \ __ / /\__ \ / / / // / / /| | /| / / __ `/ | / / _ \ __ / /\__ \ / / / // /

View File

@ -87,6 +87,9 @@ echo_default() {
echo -e "${DGN}Using MAC Address: ${BGN}Default${CL}" echo -e "${DGN}Using MAC Address: ${BGN}Default${CL}"
echo -e "${DGN}Using VLAN Tag: ${BGN}Default${CL}" echo -e "${DGN}Using VLAN Tag: ${BGN}Default${CL}"
echo -e "${DGN}Enable Root SSH Access: ${BGN}No${CL}" echo -e "${DGN}Enable Root SSH Access: ${BGN}No${CL}"
if [[ "$APP" == "Docker" || "$APP" == "Umbrel" || "$APP" == "CasaOS" || "$APP" == "Home Assistant" ]]; then
echo -e "${DGN}Enable Fuse Overlayfs (ZFS): ${BGN}No${CL}"
fi
echo -e "${DGN}Enable Verbose Mode: ${BGN}No${CL}" echo -e "${DGN}Enable Verbose Mode: ${BGN}No${CL}"
echo -e "${BL}Creating a ${APP} LXC using the above default settings${CL}" echo -e "${BL}Creating a ${APP} LXC using the above default settings${CL}"
} }
@ -300,6 +303,15 @@ advanced_settings() {
fi fi
echo -e "${DGN}Enable Root SSH Access: ${BGN}$SSH${CL}" echo -e "${DGN}Enable Root SSH Access: ${BGN}$SSH${CL}"
if [[ "$APP" == "Docker" || "$APP" == "Umbrel" || "$APP" == "CasaOS" || "$APP" == "Home Assistant" ]]; then
if (whiptail --defaultno --title "FUSE OVERLAYFS" --yesno "(ZFS) Enable Fuse Overlayfs?" 10 58); then
FUSE="yes"
else
FUSE="no"
fi
echo -e "${DGN}Enable Fuse Overlayfs (ZFS): ${BGN}$FUSE${CL}"
fi
if (whiptail --defaultno --title "VERBOSE MODE" --yesno "Enable Verbose Mode?" 10 58); then if (whiptail --defaultno --title "VERBOSE MODE" --yesno "Enable Verbose Mode?" 10 58); then
VERB="yes" VERB="yes"
else else
@ -355,15 +367,29 @@ start() {
build_container() { build_container() {
if [ "$VERB" == "yes" ]; then set -x; fi if [ "$VERB" == "yes" ]; then set -x; fi
if [[ "$APP" == "Docker" || "$APP" == "Umbrel" || "$APP" == "CasaOS" || "$APP" == "Home Assistant" ]]; then
if [ "$FUSE" == "yes" ]; then
FEATURES="fuse=1,keyctl=1,nesting=1"
else
FEATURES="keyctl=1,nesting=1"
fi
fi
if [[ "$APP" != "Docker" && "$APP" != "Umbrel" && "$APP" != "CasaOS" && "$APP" != "Home Assistant"]]; then
if [ "$CT_TYPE" == "1" ]; then if [ "$CT_TYPE" == "1" ]; then
FEATURES="nesting=1,keyctl=1" FEATURES="keyctl=1,nesting=1"
else else
FEATURES="nesting=1" FEATURES="nesting=1"
fi fi
fi
TEMP_DIR=$(mktemp -d) TEMP_DIR=$(mktemp -d)
pushd $TEMP_DIR >/dev/null pushd $TEMP_DIR >/dev/null
export FUNCTIONS_FILE_PATH="$(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/install.func)" export FUNCTIONS_FILE_PATH="$(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/install.func)"
export tz="$timezone" export tz="$timezone"
if [[ "$APP" == "Docker" || "$APP" == "Umbrel" || "$APP" == "CasaOS" || "$APP" == "Home Assistant" ]]; then
export ST="$FUSE"
fi
export DISABLEIPV6="$DISABLEIP6" export DISABLEIPV6="$DISABLEIP6"
export APPLICATION="$APP" export APPLICATION="$APP"
export VERBOSE="$VERB" export VERBOSE="$VERB"