Remote PS execute fix for puppet and shell