1
0
mirror of https://github.com/tteck/Proxmox.git synced 2024-12-25 10:42:53 +02:00

add Docker LXCs to build.func & tweaks

This commit is contained in:
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
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
# Author: tteck (tteckster)
# License: MIT

View File

@ -1,5 +1,5 @@
#!/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
# Author: tteck (tteckster)
# License: MIT

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

@ -1,5 +1,5 @@
#!/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
# Author: tteck (tteckster)
# License: MIT
@ -8,7 +8,6 @@ source <(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/docke
function header_info {
clear
cat <<"EOF"
__ __ __ __
/ / / /___ ___ / /_ ________ / /
/ / / / __ `__ \/ __ \/ ___/ _ \/ /

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

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

View File

@ -87,6 +87,9 @@ echo_default() {
echo -e "${DGN}Using MAC Address: ${BGN}Default${CL}"
echo -e "${DGN}Using VLAN Tag: ${BGN}Default${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 "${BL}Creating a ${APP} LXC using the above default settings${CL}"
}
@ -300,6 +303,15 @@ advanced_settings() {
fi
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
VERB="yes"
else
@ -355,15 +367,29 @@ start() {
build_container() {
if [ "$VERB" == "yes" ]; then set -x; fi
if [ "$CT_TYPE" == "1" ]; then
FEATURES="nesting=1,keyctl=1"
else
FEATURES="nesting=1"
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
FEATURES="keyctl=1,nesting=1"
else
FEATURES="nesting=1"
fi
fi
TEMP_DIR=$(mktemp -d)
pushd $TEMP_DIR >/dev/null
export FUNCTIONS_FILE_PATH="$(curl -s https://raw.githubusercontent.com/tteck/Proxmox/main/misc/install.func)"
export tz="$timezone"
if [[ "$APP" == "Docker" || "$APP" == "Umbrel" || "$APP" == "CasaOS" || "$APP" == "Home Assistant" ]]; then
export ST="$FUSE"
fi
export DISABLEIPV6="$DISABLEIP6"
export APPLICATION="$APP"
export VERBOSE="$VERB"