diff options
author | Daniel Baumann <daniel.baumann@open-infrastructure.net> | 2023-04-15 14:55:01 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@open-infrastructure.net> | 2024-08-29 05:49:57 +0000 |
commit | 15ceb0f6ceb7559206738ed7ee9b07e7d151ba31 (patch) | |
tree | 0eff419a9fef9dab4a2d8c0895b4b95efa3b685e /share | |
parent | Releasing version 20221223. (diff) | |
download | compute-tools-15ceb0f6ceb7559206738ed7ee9b07e7d151ba31.tar.xz compute-tools-15ceb0f6ceb7559206738ed7ee9b07e7d151ba31.zip |
Adding host variable for preseed files.
Signed-off-by: Daniel Baumann <daniel.baumann@open-infrastructure.net>
Diffstat (limited to '')
-rwxr-xr-x | share/build-scripts/debconf | 4 | ||||
-rwxr-xr-x | share/build-scripts/debconf.d/0002-preseed-debconf | 1 |
2 files changed, 5 insertions, 0 deletions
diff --git a/share/build-scripts/debconf b/share/build-scripts/debconf index 900242d..d6739ad 100755 --- a/share/build-scripts/debconf +++ b/share/build-scripts/debconf @@ -123,6 +123,8 @@ then exit 1 fi +HOST="$(echo ${NAME} | cut -d. -f1)" + Mount () { # Mounting rw bind mounts @@ -686,6 +688,7 @@ EOF sed -e "s|@FILE@|${FILE}|g" \ -e "s|@NAME@|${NAME}|g" \ + -e "s|@HOST@|${HOST}|g" \ -e "s|@IPV4_ADDRESS1@|${IPV4_ADDRESS1}|g" \ -e "s|@IPV4_ADDRESS1_PART1@|${IPV4_ADDRESS1_PART1}|g" \ -e "s|@IPV4_ADDRESS1_PART2@|${IPV4_ADDRESS1_PART2}|g" \ @@ -1185,6 +1188,7 @@ trap 'Umount' EXIT HUP INT QUIT TERM umask 0022 export NAME +export HOST Debconf diff --git a/share/build-scripts/debconf.d/0002-preseed-debconf b/share/build-scripts/debconf.d/0002-preseed-debconf index fcb9006..e4b5f44 100755 --- a/share/build-scripts/debconf.d/0002-preseed-debconf +++ b/share/build-scripts/debconf.d/0002-preseed-debconf @@ -93,6 +93,7 @@ do fi sed -e "s|@NAME@|${NAME}|g" \ + -e "s|@HOST@|${HOST}|g" \ -e "s|@IPV4_ADDRESS1@|${IPV4_ADDRESS1}|g" \ -e "s|@IPV4_ADDRESS1_PART1@|${IPV4_ADDRESS1_PART1}|g" \ -e "s|@IPV4_ADDRESS1_PART2@|${IPV4_ADDRESS1_PART2}|g" \ |