Use regex to handle ServiceDiscovery and Dashboard

Jira-issue: WP-984