Skip to content

Commit

Permalink
dont error when duplicat hw found
Browse files Browse the repository at this point in the history
Signed-off-by: yzamir <[email protected]>
  • Loading branch information
yaacov authored and mnecas committed Aug 29, 2024
1 parent 4d3e321 commit 456ae6d
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions virt-v2v/cold/scripts/rhel/run/network_config_util.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ extract_mac_ip() {
udev_from_ifcfg() {
# Check if the network scripts directory exists
if [[ ! -d "$NETWORK_SCRIPTS_DIR" ]]; then
echo "Warning: Directory $NETWORK_SCRIPTS_DIR does not exist." >&2
echo "Warning: Directory $NETWORK_SCRIPTS_DIR does not exist."
return 0
fi

Expand All @@ -64,7 +64,7 @@ udev_from_ifcfg() {
udev_from_nm() {
# Check if the network connections directory exists
if [[ ! -d "$NETWORK_CONNECTIONS_DIR" ]]; then
echo "Warning: Directory $NETWORK_CONNECTIONS_DIR does not exist." >&2
echo "Warning: Directory $NETWORK_CONNECTIONS_DIR does not exist."
return 0
fi

Expand Down Expand Up @@ -97,8 +97,8 @@ check_dupe_hws() {

# If duplicates are found, print an error and exit
if [ -n "$dupes" ]; then
echo "ERR: Duplicate hw: $dupes"
exit 2
echo "Warning: Duplicate hw: $dupes"
return 0
fi

echo "$input"
Expand Down

0 comments on commit 456ae6d

Please sign in to comment.