如何使用Codeigniter - CPanel通配符子域使用动态子域

I'm currently using CodeIgniter 3. I want to create dynamic subdomains like team1.domain.com, team2.domain.com, etc.

These domains need to point to the controller Team and a specifically to the show_Team method in the that controller.

--------------------------------------------
$route['team/(:any)'] = "Team/show_Team"; 
--------------------------------------------

I had severall rules in the .htaccess, but these do a redirect to /team/team1, but I want to work from the subdomain.

Like as said team1.domain.com