Role support

This should be `if self.instance.state == 'running' and profile is not None:`