Add get_hosts and refactor the code.
Merge feature/generate-host-parameter.