#!/bin/bash

cat /dev/null > etc/sysconfig/network-scripts/ifcfg-eth0

cat > /etc/sysconfig/network-scripts/ifcfg-eth0 <<EOF
#network-config
TYPE=Ethernet
BOOTPROTO=static
DEFROUTE=yes
DEVICE=eth0
ONBOOT=yes
IPADDR=127.0.0.1
NETMASK=255.255.255.255
GATEWAY=1.1.1.1
DNS1=114.114.114.114
DNS2=5.5.5.5

EOF

systemctl restart NetworkManager


rm -rf /tmp/change.sh
