You've already forked ansible-role-common
Add static/dhcp ip helpers for NetworkManager
This commit is contained in:
8
files/helpers/set_dhcp_ip.sh
Normal file
8
files/helpers/set_dhcp_ip.sh
Normal file
@@ -0,0 +1,8 @@
|
||||
#!/bin/bash
|
||||
|
||||
# This script will reset the IP Address back to default of DHCP
|
||||
# helpful for a pending restore
|
||||
|
||||
/bin/nmcli c m "System eth0" ipv4.method auto
|
||||
/bin/nmcli c m "System eth0" ipv4.address "" ipv4.gateway ""
|
||||
/bin/nmcli connection up "System eth0"
|
||||
Reference in New Issue
Block a user