From 870ea5bb5e15115c801cb14bb463b1e8496fe315 Mon Sep 17 00:00:00 2001 From: Om Kumar Date: Mon, 6 Jul 2015 19:09:05 +0530 Subject: [PATCH] Removes hardcoded refrences for ethernet interface Remove hardcoded refrences for ethernet interfaces from ironic-agent and sets a dependency on dhcp-all-interfaces to ensure it works for all interfaces for all other operating systems. Change-Id: I7ae6d1c5bd9911ef3db45187c0010cf0973badf1 Closes-Bug: #1471802 --- elements/ironic-agent/element-deps | 1 + elements/ironic-agent/post-install.d/80-ironic-agent | 8 -------- 2 files changed, 1 insertion(+), 8 deletions(-) diff --git a/elements/ironic-agent/element-deps b/elements/ironic-agent/element-deps index 715c11e2f..3f5c9a851 100644 --- a/elements/ironic-agent/element-deps +++ b/elements/ironic-agent/element-deps @@ -1 +1,2 @@ +dhcp-all-interfaces source-repositories diff --git a/elements/ironic-agent/post-install.d/80-ironic-agent b/elements/ironic-agent/post-install.d/80-ironic-agent index 6a3b8b003..eb0009811 100755 --- a/elements/ironic-agent/post-install.d/80-ironic-agent +++ b/elements/ironic-agent/post-install.d/80-ironic-agent @@ -10,11 +10,3 @@ install-packages -e python-dev git cloud-init rm -rf /tmp/ironic-python-agent sudo systemctl disable iptables.service - -#configs for additional interfaces -SYSCONFIG_PATH=/etc/sysconfig/network-scripts -for IFACE_NUM in 1 2 -do - sudo cp $SYSCONFIG_PATH/ifcfg-eth0 $SYSCONFIG_PATH/ifcfg-eth$IFACE_NUM - sudo sed -i "s/eth0/eth$IFACE_NUM/g" $SYSCONFIG_PATH/ifcfg-eth$IFACE_NUM -done