This topic contains 2 replies, has 2 voices, and was last updated by
April 5, 2016 at 8:39 pm #37279ParticipantTopics: 4Replies: 8Points: 0Rank: Member
I am a developer, trying to understand DSC better.
Regular.ps1 – this script copy files from \\smb.production share to c:\
DSC.ps1- this script create DSC.MOF file, when i Call start-dscconfiguration DSC this will copy files from \\smb.production share to c:\.
My question is what is difference between pushing Regular.ps1 through SCCM to all my servers vc DSC push or which is efficient way ?
April 6, 2016 at 4:05 am #37299MemberTopics: 9Replies: 2322Points: 0Rank: Member
DSC gives a few advantages over traditional imperative scripts:
– Idempotent resources. We're expected to write resources in such a way that they can be executed over and over again, and will leave the system in exactly the state it's supposed to be. I don't know about you, but I didn't always put quite that level of rigor into my older scripts. 🙂
– Monitored for drift over time. Depending on how you've configured the LCM, it will keep an eye on the things you've told it to configure, and either log an event when something's changed, or it'll just correct the problem.
– Declarative syntax. Easier for non-developers to write and maintain, if that workflow is appropriate for your organization.
That said, if you want this to be a one-time file copy, there's really no reason to bother with DSC. (And in fact, you'd be overwriting any other DSC configuration that was already present on the target systems, if you used it for such a small task.)
April 6, 2016 at 5:01 am #37309ParticipantTopics: 4Replies: 8Points: 0Rank: Member
Awesome.thanks. it gave me some idea about DSC.
The topic ‘DSC ps1 VS Regular.ps1’ is closed to new replies.