diff options
Diffstat (limited to 'share/scripts/debconf.d/0003-debconf')
-rwxr-xr-x | share/scripts/debconf.d/0003-debconf | 58 |
1 files changed, 29 insertions, 29 deletions
diff --git a/share/scripts/debconf.d/0003-debconf b/share/scripts/debconf.d/0003-debconf index 2592cf6..1773b09 100755 --- a/share/scripts/debconf.d/0003-debconf +++ b/share/scripts/debconf.d/0003-debconf @@ -696,13 +696,13 @@ Network_defaults () HOSTNAME_SHORT="$(echo veth-$(echo ${NAME} | cut -c-8)-0)" VETH_NAME="${HOSTNAME_SHORT}" - NETWORK0_VETH="${NETWORK0_VETH:-$VETH_NAME}" - NETWORK0_BRIDGE="${NETWORK0_BRIDGE:-bridge0}" - NETWORK0_IPV4_METHOD="${NETWORK0_IPV4_METHOD:-dhcp}" - NETWORK0_IPV4_ADDRESS="${NETWORK0_IPV4_ADDRESS:-192.168.1.2}" - NETWORK0_IPV4_NETMASK="${NETWORK0_IPV4_NETMASK:-255.255.255.0}" + NETWORK1_VETH="${NETWORK1_VETH:-$VETH_NAME}" + NETWORK1_BRIDGE="${NETWORK1_BRIDGE:-bridge0}" + NETWORK1_IPV4_METHOD="${NETWORK1_IPV4_METHOD:-dhcp}" + NETWORK1_IPV4_ADDRESS="${NETWORK1_IPV4_ADDRESS:-192.168.1.2}" + NETWORK1_IPV4_NETMASK="${NETWORK1_IPV4_NETMASK:-255.255.255.0}" - if [ "${NETWORK0_IPV4_METHOD}" = "static" ] && [ -e /etc/resolv.conf ] + if [ "${NETWORK1_IPV4_METHOD}" = "static" ] && [ -e /etc/resolv.conf ] then NAMESERVER_SERVER="${NAMESERVER_SERVER:-$(if [ -e /etc/resolv.conf ]; then awk '/^nameserver / {$1=""; print $0}' /etc/resolv.conf; fi)}" # Workaround to get rid of newlines since debconf can not handle multiline return value in assignments @@ -717,31 +717,31 @@ Network_defaults () Network () { db_get cnt-debconf/network1/bridge - NETWORK0_BRIDGE="${RET}" # string (w/o empty) + NETWORK1_BRIDGE="${RET}" # string (w/o empty) db_get cnt-debconf/network1/veth - NETWORK0_VETH="${RET}" # string (w/o empty) + NETWORK1_VETH="${RET}" # string (w/o empty) db_get cnt-debconf/network1/ipv4-method - NETWORK0_IPV4_METHOD="${RET}" # select + NETWORK1_IPV4_METHOD="${RET}" # select db_get cnt-debconf/network1/ipv4-comment - NETWORK0_IPV4_COMMENT="${RET}" # string (w/ empty) + NETWORK1_IPV4_COMMENT="${RET}" # string (w/ empty) db_get cnt-debconf/network1/ipv4-address - NETWORK0_IPV4_ADDRESS="${RET}" # string (w/o empty) + NETWORK1_IPV4_ADDRESS="${RET}" # string (w/o empty) db_get cnt-debconf/network1/ipv4-gateway - NETWORK0_IPV4_GATEWAY="${RET}" # string (w/ empty) + NETWORK1_IPV4_GATEWAY="${RET}" # string (w/ empty) db_get cnt-debconf/network1/ipv4-netmask - NETWORK0_IPV4_NETMASK="${RET}" # string (w/o empty) + NETWORK1_IPV4_NETMASK="${RET}" # string (w/o empty) db_get cnt-debconf/network1/ipv4-post-up - NETWORK0_IPV4_POST_UP="${RET}" # string (w/ empty) + NETWORK1_IPV4_POST_UP="${RET}" # string (w/ empty) db_get cnt-debconf/network1/ipv4-post-down - NETWORK0_IPV4_POST_DOWN="${RET}" # string (w/ empty) + NETWORK1_IPV4_POST_DOWN="${RET}" # string (w/ empty) db_get cnt-debconf/nameserver/server NAMESERVER_SERVER="${RET}" # string (w/ empty) @@ -757,31 +757,31 @@ Network () Network_defaults - db_set cnt-debconf/network1/bridge "${NETWORK0_BRIDGE}" + db_set cnt-debconf/network1/bridge "${NETWORK1_BRIDGE}" db_fset cnt-debconf/network1/bridge seen false - db_set cnt-debconf/network1/veth "${NETWORK0_VETH}" + db_set cnt-debconf/network1/veth "${NETWORK1_VETH}" db_fset cnt-debconf/network1/veth seen false - db_set cnt-debconf/network1/ipv4-method "${NETWORK0_IPV4_METHOD}" + db_set cnt-debconf/network1/ipv4-method "${NETWORK1_IPV4_METHOD}" db_fset cnt-debconf/network1/ipv4-method seen false - db_set cnt-debconf/network1/ipv4-comment "${NETWORK0_IPV4_COMMENT}" + db_set cnt-debconf/network1/ipv4-comment "${NETWORK1_IPV4_COMMENT}" db_fset cnt-debconf/network1/ipv4-comment seen false - db_set cnt-debconf/network1/ipv4-address "${NETWORK0_IPV4_ADDRESS}" + db_set cnt-debconf/network1/ipv4-address "${NETWORK1_IPV4_ADDRESS}" db_fset cnt-debconf/network1/ipv4-address seen false - db_set cnt-debconf/network1/ipv4-gateway "${NETWORK0_IPV4_GATEWAY}" + db_set cnt-debconf/network1/ipv4-gateway "${NETWORK1_IPV4_GATEWAY}" db_fset cnt-debconf/network1/ipv4-gateway seen false - db_set cnt-debconf/network1/ipv4-netmask "${NETWORK0_IPV4_NETMASK}" + db_set cnt-debconf/network1/ipv4-netmask "${NETWORK1_IPV4_NETMASK}" db_fset cnt-debconf/network1/ipv4-netmask seen false - db_set cnt-debconf/network1/ipv4-post-up "${NETWORK0_IPV4_POST_UP}" + db_set cnt-debconf/network1/ipv4-post-up "${NETWORK1_IPV4_POST_UP}" db_fset cnt-debconf/network1/ipv4-post-up seen false - db_set cnt-debconf/network1/ipv4-post-down "${NETWORK0_IPV4_POST_DOWN}" + db_set cnt-debconf/network1/ipv4-post-down "${NETWORK1_IPV4_POST_DOWN}" db_fset cnt-debconf/network1/ipv4-post-down seen false db_set cnt-debconf/nameserver/server "${NAMESERVER_SERVER}" @@ -801,15 +801,15 @@ Network () db_go db_get cnt-debconf/network1/bridge - NETWORK0_BRIDGE="${RET}" # select + NETWORK1_BRIDGE="${RET}" # select db_get cnt-debconf/network1/veth - NETWORK0_VETH="${RET}" # select + NETWORK1_VETH="${RET}" # select db_get cnt-debconf/network1/ipv4-method - NETWORK0_IPV4_METHOD="${RET}" # select + NETWORK1_IPV4_METHOD="${RET}" # select - case "${NETWORK0_IPV4_METHOD}" in + case "${NETWORK1_IPV4_METHOD}" in none|dhcp) ;; @@ -896,7 +896,7 @@ Network () NUMBER="$((${NUMBER} + 1))" done - NETWORK_NUMBER="${NUMBER}" + NETWORK_NUMBER="$((${NUMBER} - 1))" db_get cnt-debconf/nameserver/server NAMESERVER_SERVER="${RET}" # string (w/ empty) |