Forums on Intune, SCCM, and Windows 11

Welcome to the forums. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your topics and posts, as well as connect with other members through your own private inbox!

NEW OSD run CMD from local DP share

  • Thread starter Thread starter MartinDT
  • Start date Start date
  • Replies Replies 3
  • Views Views 2K

MartinDT

Member
Messages
7
Reaction score
0
Points
1
Hi,
I'm trying to run an OSD task, (Its not windows, hence the odd way)..
I want to run a CMD script as part of the OSD to deploy the image, but i'd like it to run from a share from the local DP at that site. all PXE boot.

The script is \\Server\Share1\deploy.cmd nice and simple, but we have 10 sites each with a DP, so i'd like to try to find a script to find the local DP at the site, and run it from that.. like the below,
Get-LocalDPName = LocalDP
\\LocalDP\Share1\deploy.cmd

I've been searching for ages, but can't seem to find a way.
If anyone has any ideas, that would be great, if not its 10 Task Sequences, each pointing to the sites DP.

Thanks,
 
This will not work for security reasons.

Why don't you include the cmd and all source files within the package? Why is it 10 TS?
 
I think I've found a way round it.
Using variables based on the Default gateway, I've set it to map a to a share based on what the default gateway is, and a combination of if statements.
I wasn't able to use a package, as the task cleans the disk, and then copies some bin files to it, so there was no where to download it do.
 
I wasn't able to use a package, as the task cleans the disk, and then copies some bin files to it, so there was no where to download it do.
So a Program doesn't need any source files to work. But if you are copying files aren't those source files or a batch files or Posh script?
 
Back
Top