We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fa7173e commit d6f044aCopy full SHA for d6f044a
dsc/examples/file.bicep
@@ -0,0 +1,22 @@
1
+// This example demonstrates how to create a file using the Windows PowerShell DSC extension.
2
+// The file is created in the C:\DSC directory on the target machine.
3
+// You should at least have the Bicep CLI v0.34.34 installed to run this example with experimental feature desiredStateConfiguration turned on.
4
+
5
+targetScope = 'desiredStateConfiguration'
6
7
+resource powerShellAdapter 'Microsoft.Windows/WindowsPowerShell@2025-01-07' = {
8
+ name: 'Use Bicep to create file'
9
+ properties: {
10
+ resources: [
11
+ {
12
+ name: 'File'
13
+ type: 'PSDesiredStateConfiguration/File'
14
15
+ Ensure: 'Present'
16
+ Type: 'Directory'
17
+ DestinationPath: 'C:\\DSC\\'
18
+ }
19
20
+ ]
21
22
+}
0 commit comments