Skip to content
This repository was archived by the owner on May 15, 2018. It is now read-only.

Conversation

@craig-martin
Copy link
Contributor

Ran into two issues using this resource:

  1. The resource would fail in the LCM with access-denied, so I plumbed in the Credential parameter and used New-PSSession, like in Test-TargetResource
  2. The Set-TargetResource would fail if the ScheduledTask already exists. I would usually do a property-by-property diff but took the lazy solution to just clobber the existing ScheduledTask, allowing the new one to be created.

Craig Martin added 2 commits October 21, 2014 13:33
the DSC resource was failing in the LCM with Access-Denied, so I plumbed
the Credential into the Set-TargetResource function and used it with
New-PSSession (same pattern I saw in Test-TargetResource)
@usepowershell
Copy link
Contributor

Test-TargetResource already does the property by property diff, so clobber and replace is fine. Thanks for the work on the resource. This was my next resource to get implemented, but I just got to testing it.

usepowershell added a commit that referenced this pull request Oct 21, 2014
Fix for ScheduledTask - existing Job, and using Credentials
@usepowershell usepowershell merged commit d6011e3 into PowerShellOrg:master Oct 21, 2014
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants