agiledivider / vagrant-hostsupdater

MIT License
1.15k stars 129 forks source link

Does not remove aliases that are not defined #150

Open kallookoo opened 6 years ago

kallookoo commented 6 years ago

If the option to remove_suspend the plugin is set to false, it does not delete the old entries in the file when change the aliases.

cgsmith commented 6 years ago

Hi @kallookoo - did you try removing config.hostsupdater.remove_on_suspend = false ?

See this part of the readme

kallookoo commented 6 years ago

Hi @cgsmith I say that it does not check when vagrant starts if in the hosts file there are domains that do not exist inside the aliases option, but it does add the new domains if not exists, when remove_on_suspend = false.

Example: 1.- vagrant up with 5 aliases 'a,b,c,d,e' 2.- vagrant halt 3.- remove 'e' and add 'f' in aliases option 4.- vagrant up, this plugin add new domain 'f' but not remove 'e'