Clear resources command.

This command removes all resources in platform, stopping them first if they are active.