I need to use the command line in order to add a new host resolution on a temporary basis. I use centos.
I need a new localhost
resolution such as the following:
127.0.0.1 something.localhost
I this possible with Centos? If so how?
Using the HOSTALIASES
env variable does the trick:
echo 'something.localhost localhost' >> ~/.hosts
export HOSTALIASES=~/.hosts