Hey all,
Im having trouble with something i thought i would be pretty easy. but i keep failing short it seems.
We have several domains in our shop, so im trying to run scripts on my machine that connect to a different domain and run under my account for that domain instead.
what id like to do, is either state at the top of the script what account to run the script as, or change the cred during the script based on a hash table. but i cant work out how to get close to this. playing around with invoke-command it looks like it always tries to run on the remote machine and a lot of the remote machines dont have powershell installed so they fail. when i try and use something like Credential it fails out with a login failed.
Any suggestions?