Fixes for recent changes (#87)
* some fixes * set fixes * some rest * add shellcheck ignore and explaination * fix iocage install dir not being exported * reset branch to dev
This commit is contained in:
parent
2c75cfe0ea
commit
8659f2c252
@ -28,8 +28,43 @@ example: example
|
||||
pkgs: mono
|
||||
|
||||
plex: plex
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
beta: false
|
||||
|
||||
lidarr: lidarr
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
||||
sonarr: sonarr
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
||||
radarr: radarr
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
||||
kms: kms
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
||||
jackett: jackett
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
||||
organizr: organizr
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
||||
tautulli: tautulli
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
||||
transmission: transmission
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
||||
|
||||
nextcloud: nextcloud
|
||||
ip4_addr: 192.168.1.99/24
|
||||
gateway: 192.168.1.1
|
||||
|
12
global.sh
12
global.sh
@ -3,15 +3,15 @@
|
||||
|
||||
# yml Parser function
|
||||
# Based on https://gist.github.com/pkuczynski/8665367
|
||||
# shellcheck disable=SC2086
|
||||
#
|
||||
# This function is very picky and complex. Ignore with shellcheck for now.
|
||||
# shellcheck disable=SC2086,SC2155
|
||||
parse_yaml() {
|
||||
prefix=${2}
|
||||
s='[[:space:]]*' w='[a-zA-Z0-9_]*' fs=$(echo @|tr @ '\034')
|
||||
local prefix
|
||||
local s w fs
|
||||
local prefix=${2}
|
||||
local s='[[:space:]]*' w='[a-zA-Z0-9_]*' fs=$(echo @|tr @ '\034')
|
||||
sed -ne "s|^\($s\)\($w\)$s:$s\"\(.*\)\"$s\$|\1$fs\2$fs\3|p" \
|
||||
-e "s|^\($s\)\($w\)$s:$s\(.*\)$s\$|\1$fs\2$fs\3|p" "${1}" |
|
||||
awk -F"${fs}" '{
|
||||
awk -F$fs '{
|
||||
indent = length($1)/2;
|
||||
vname[indent] = $2;
|
||||
for (i in vname) {if (i > indent) {delete vname[i]}}
|
||||
|
@ -100,8 +100,10 @@ while getopts ":i:r:u:d:g:h" opt
|
||||
esac
|
||||
done
|
||||
|
||||
# auto detect iocage install location
|
||||
global_dataset_iocage=$(zfs get -H -o value mountpoint $(iocage get -p)/iocage)
|
||||
global_dataset_iocage=${global_dataset_iocage#/mnt/}
|
||||
export global_dataset_iocage
|
||||
|
||||
# Parse the Config YAML
|
||||
# shellcheck disable=SC2046
|
||||
|
Loading…
Reference in New Issue
Block a user