Change phase to check for dracut-regenerate in iscsi-boot
There is an use of get_image_element_array on the environment.d phase, for the iscsi-boot element. This function is not available on that step. So moving the check at next step, extra-data-d, where it is available. Change-Id: I89cfe565492142c2f7962109360fcbcebadfd469
This commit is contained in:
parent
56c72a0139
commit
853e13c6c3
@ -1,10 +1,4 @@
|
|||||||
if [[ $DISTRO_NAME = "centos7" ]]; then
|
if [[ $DISTRO_NAME = "centos7" ]]; then
|
||||||
eval declare -A image_elements=($(get_image_element_array))
|
|
||||||
found=0
|
|
||||||
for i in "${!image_elements[@]}"; do
|
|
||||||
[ "$i" = "dracut-regenerate" ] && found=1
|
|
||||||
done
|
|
||||||
[ "$found" = 0 ] && echo "The dracut-regenerate element is required!" && exit 1
|
|
||||||
|
|
||||||
DIB_DRACUT_ENABLED_MODULES+="
|
DIB_DRACUT_ENABLED_MODULES+="
|
||||||
- name: network
|
- name: network
|
||||||
|
@ -0,0 +1,17 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
if [ ${DIB_DEBUG_TRACE:-1} -gt 0 ]; then
|
||||||
|
set -x
|
||||||
|
fi
|
||||||
|
set -eu
|
||||||
|
set -o pipefail
|
||||||
|
|
||||||
|
if [[ $DISTRO_NAME = "centos7" ]]; then
|
||||||
|
eval declare -A image_elements=($(get_image_element_array))
|
||||||
|
found=0
|
||||||
|
for i in "${!image_elements[@]}"; do
|
||||||
|
[ "$i" = "dracut-regenerate" ] && found=1
|
||||||
|
done
|
||||||
|
[ "$found" = 0 ] && echo "The dracut-regenerate element is required!" && exit 1
|
||||||
|
|
||||||
|
fi
|
Loading…
Reference in New Issue
Block a user