Quantcast
Channel: Windows 8.1 Installation, Setup, and Deployment forum
Viewing all articles
Browse latest Browse all 5362

MDT 2013 Task Sequence Commands and Scripts to run as domain user

$
0
0

Hello,

I have a task sequence which deploys an operating system, installs some applications, then runs some scripts and commands, finally joins the domain, then runs some further scripts and commands.

the first set of commands and scripts configures stuff local to the machine, all passes fine.

the second set of commands and scripts (powershell scripts, the commands vary I can change them if required to make this work), must run as a domain user (the domain admin account). this is because these commands perform things like joining the computer account to groups in Active Directory. I know my command/script works fine when I manually run it using a domain admin account, I need to be able to run this as a domain admin during the task sequence.

I notice in the Run Command TS step I can choose to run as a difference user, so I select the domain admin to run it under... thing is, I am trying to run a powershell script and it doesnt seem to like it. in the command line box i have entered the following

%SCRIPTROOT%\CustomScripts\JoinGroups.ps1

and I set the "Run this step as the following account" to be the domain admin, but it still doesn't work. If i normally run a PS script i usually select the TS step of running a PS script, not a command... however the PS script step doesnt give you the option of running it as a different user account.

any suggestions please?

many thanks

Steve


Viewing all articles
Browse latest Browse all 5362

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>