summaryrefslogtreecommitdiff
path: root/DOC_CHANGES.md
diff options
context:
space:
mode:
authorJay Mundrawala <jdmundrawala@gmail.com>2015-08-25 13:25:42 -0700
committerJay Mundrawala <jdmundrawala@gmail.com>2015-08-25 13:25:42 -0700
commitd2102fdf7451029622a23883dc1fb262b9930abb (patch)
treeff92f4331305c85c0f6a517d7094bca779523014 /DOC_CHANGES.md
parenteee28f45c06123c94bb7d2fd26814dd3858e930d (diff)
downloadchef-d2102fdf7451029622a23883dc1fb262b9930abb.tar.gz
Add doc changes for dsc_script + ps_credential
Diffstat (limited to 'DOC_CHANGES.md')
-rw-r--r--DOC_CHANGES.md31
1 files changed, 31 insertions, 0 deletions
diff --git a/DOC_CHANGES.md b/DOC_CHANGES.md
index b8eb61d12c..4c07dea872 100644
--- a/DOC_CHANGES.md
+++ b/DOC_CHANGES.md
@@ -6,6 +6,37 @@ Example Doc Change:
Description of the required change.
-->
+### PSCredential Support for `dsc_script`
+
+`dsc_script` now supports the use of `ps_credential` to create a PSCredential
+object similar to `dsc_resource`. The `ps_credential` helper function takes in
+a string and when `to_s` is called on it, produces an object that can be embedded
+in your `dsc_script`. For example, you can write:
+
+```ruby
+dsc_script 'create-foo-user' do
+ code <<-EOH
+ User FooUser
+ {
+ UserName = 'FooUser'
+ Password = #{ps_credential('FooBarBaz1!')}
+ }
+ EOH
+ configuration_data <<-EOH
+ @{
+ AllNodes = @(
+ @{
+ NodeName = "localhost";
+ CertificateID = 'A8DB81D8059F349F7EF19104399B898F701D4167'
+ }
+ )
+ }
+ EOH
+end
+```
+
+Note, you still need to configure the CertificateID in the LCM.
+
### chef-client -j JSON
Add to the [description of chef-client options](https://docs.chef.io/ctl_chef_client.html#options):