added create_host function