Fix working directory used for remote metadata command generation.

In short - should fix bam outputs for LWR jobs when setting metadata on remote resource. Thanks to @natefoo for tracking down problem.
Another fix for remotely populated metadata FileParameters.

Requires update to remote LWR as well.