Skip to content

Commit 4a65468

Browse files
committed
Merge branch 'main' into add-sshdconfig-default-shell
2 parents 290adb2 + 9dee199 commit 4a65468

File tree

587 files changed

+72316
-675
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

587 files changed

+72316
-675
lines changed

.pipelines/DSC-Official.yml

Lines changed: 29 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -133,9 +133,10 @@ extends:
133133
variables:
134134
ob_outputDirectory: '$(Build.ArtifactStagingDirectory)'
135135
ob_sdl_tsa_configFile: '$(Build.SourcesDirectory)\DSC\.config\tsaoptions.json'
136-
ob_sdl_sbom_enabled: true
137-
ob_signing_setup_enabled: true
138-
ob_sdl_codeql_compiled_enabled: true
136+
ob_sdl_sbom_enabled: false
137+
ob_signing_setup_enabled: false
138+
ob_sdl_codeql_compiled_enabled: false
139+
ob_restore_phase: true
139140
pool:
140141
type: windows
141142
steps:
@@ -152,17 +153,39 @@ extends:
152153
Copy-Item "$(Pipeline.Workspace)/drop_BuildAndSign_BuildWin_x64/*.msix" ./bin/msix -Verbose
153154
Copy-Item "$(Pipeline.Workspace)/drop_BuildAndSign_BuildWin_arm64/*.msix" ./bin/msix -Verbose
154155
./build.ps1 -PackageType msixbundle
155-
Copy-Item ./bin/*.msixbundle "$(ob_outputDirectory)"
156+
Copy-Item "$(Build.SourcesDirectory)/DSC/bin/*.msixbundle" "$(ob_outputDirectory)"
156157
displayName: 'Create msixbundle'
157158
condition: succeeded()
159+
160+
- job: SignMsixBundle
161+
dependsOn: CreateMsixBundle
162+
variables:
163+
ob_outputDirectory: '$(Build.ArtifactStagingDirectory)'
164+
ob_sdl_sbom_enabled: false
165+
ob_signing_setup_enabled: true
166+
ob_sdl_codeql_compiled_enabled: false
167+
pool:
168+
type: windows
169+
steps:
170+
- task: DownloadPipelineArtifact@2
171+
inputs:
172+
buildType: 'current'
173+
artifact: drop_BuildAndSign_CreateMsixBundle
174+
itemPattern: |
175+
**/*.msixbundle
176+
targetPath: '$(Build.ArtifactStagingDirectory)/downloads'
177+
displayName: Download MsixBundle
158178
- task: onebranch.pipeline.signing@1
159179
displayName: Sign MsixBundle
160180
condition: succeeded()
161181
inputs:
162182
command: 'sign'
163-
signing_profile: $(MSIXProfile)
183+
signing_profile: 'Dynamic-WINMSAPP1ST'
164184
files_to_sign: '*.msixbundle'
165-
search_root: '$(ob_outputDirectory)'
185+
search_root: '$(Build.ArtifactStagingDirectory)/downloads'
186+
- pwsh: |
187+
Copy-Item "$(Build.ArtifactStagingDirectory)/downloads/*.msixbundle" "$(ob_outputDirectory)"
188+
displayName: 'Copy MsixBundle to output directory'
166189
167190
- job: BuildLinuxMusl
168191
dependsOn: SetPackageVersion

CHANGELOG.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -121,7 +121,7 @@ changes since the last release, see the [diff on GitHub][unreleased].
121121
- Added support for extensions to DSC. You can now use the `dsc extension list` command to
122122
enumerate available extensions. DSC now supports a single extension capability, `discover`, which
123123
returns JSON objects indicating where to find DSC resource manifests that aren't in the `PATH` or
124-
`DSC_PATH`, as with resources installed as Appx packages.
124+
`DSC_RESOURCE_PATH`, as with resources installed as Appx packages.
125125

126126
Now when DSC performs discovery, it recursively discovers extensions and resources on the system.
127127

@@ -135,7 +135,7 @@ changes since the last release, see the [diff on GitHub][unreleased].
135135
- [#760][#760]
136136
- [#762][#762]
137137

138-
- Addes support for passing parameters to the `dsc config` commands from stdin. You can pass
138+
- Adds support for passing parameters to the `dsc config` commands from stdin. You can pass
139139
_either_ the configuration document or parameters file contents to the command from stdin, but
140140
not both. This enables securely passing sensitive parameters to DSC without writing them to a
141141
file or defining them as an environment variable.

CONTRIBUTING.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,11 @@ Please read the rest of this document to ensure a smooth contribution process.
2626

2727
### Contributing to documentation related to DSC
2828

29-
Please see the [PowerShell-Docs-DSC](https://github.com/MicrosoftDocs/PowerShell-Docs-DSC/) repository for details.
29+
You can contribute to documentation either in the `docs` folder of this repository
30+
or in the [PowerShell-Docs-DSC](https://github.com/MicrosoftDocs/PowerShell-Docs-DSC/) repository.
31+
32+
> [!NOTE]
33+
> Documentation contributed to the `docs` folder in this repository is periodically synced to the [PowerShell-Docs-DSC](https://github.com/MicrosoftDocs/PowerShell-Docs-DSC/) repository.
3034
3135
### Contributing to documentation related to maintaining or contributing to the DSC project
3236

README.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
# DSCv3
22

33
> [!NOTE]
4-
> This repo isn't accepting code contributions. It's public and open source to show progress and
5-
> enable feedback. Once we're at a feature complete state, we can start taking code contributions.
4+
> We welcome code contributions to this repository. For guidelines on how to contribute,
5+
> see our [CONTRIBUTING.md](CONTRIBUTING.md).
6+
> Your feedback and participation help us improve DSCv3 for everyone.
67
78
## What's DSCv3?
89

@@ -22,7 +23,7 @@ DSCv3 differs from PowerShell DSC in a few important ways:
2223

2324
- DSCv3 doesn't depend on PowerShell. You can use DSCv3 without PowerShell installed and manage
2425
resources written in bash, python, C#, Go, or any other language.
25-
- DSCv3 use of PowerShell based resources does not depend on PSDesiredStateConfiguration module
26+
- DSCv3 use of PowerShell based resources does not depend on [PSDesiredStateConfiguration][00] module
2627
- DSCv3 doesn't include a local configuration manager. DSCv3 is invoked as a command. It doesn't
2728
run as a service.
2829
- Non-PowerShell resources define their schemas with JSON files, not MOF files.

build.ps1

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -175,6 +175,27 @@ if ($null -ne $packageType) {
175175
$BuildToolsPath = "${env:ProgramFiles(x86)}\Microsoft Visual Studio\2022\BuildTools\VC\Tools\MSVC"
176176

177177
& $rustup default stable
178+
179+
## Test if Node is installed
180+
## Skipping upgrade as users may have a specific version they want to use
181+
if (!(Get-Command 'node' -ErrorAction Ignore)) {
182+
Write-Verbose -Verbose "Node.js not found, installing..."
183+
if (!$IsWindows) {
184+
if (Get-Command 'brew' -ErrorAction Ignore) {
185+
brew install node@24
186+
} else {
187+
Write-Warning "Homebrew not found, please install Node.js manually"
188+
}
189+
}
190+
else {
191+
if (Get-Command 'winget' -ErrorAction Ignore) {
192+
Write-Verbose -Verbose "Using winget to install Node.js"
193+
winget install OpenJS.NodeJS --accept-source-agreements --accept-package-agreements --source winget --silent
194+
} else {
195+
Write-Warning "winget not found, please install Node.js manually"
196+
}
197+
}
198+
}
178199
}
179200

180201
if (!$SkipBuild -and !$SkipLinkCheck -and $IsWindows -and !(Get-Command 'link.exe' -ErrorAction Ignore)) {

docs/overview.md

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -86,14 +86,6 @@ To install DSC on any platform:
8686
1. Expand the release archive.
8787
1. Add the folder containing the expanded archive contents to the `PATH`.
8888

89-
> [!NOTE]
90-
> When downloading the latest release on Windows platform, make sure after extraction,
91-
> the files are unblocked. You can do this using the following PowerShell command:
92-
>
93-
> ```powershell
94-
> Get-ChildItem -Path <path-to-expanded-folder> -Recurse | Unblock-File
95-
> ```
96-
9789
### Install DSC on Windows with WinGet
9890

9991
The following commands can be used to install DSC using the published `winget` packages:

docs/reference/cli/config/export.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,18 @@ dsc config export [Options] --input <INPUT>
3131
cat <FILE> | dsc config export [Options] --file -
3232
```
3333

34+
### Configuration document from file with parameters from stdin
35+
36+
```sh
37+
cat <PARAMETERS_FILE> | dsc config --parameters-file - export [Options] --file <FILE>
38+
```
39+
40+
### Configuration document from option string with parameters from stdin
41+
42+
```sh
43+
cat <PARAMETERS_FILE> | dsc config --parameters-file - export [Options] --input <INPUT>
44+
```
45+
3446
## Description
3547

3648
The `export` subcommand generates a configuration document that includes every instance of a set of

docs/reference/cli/config/get.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,18 @@ dsc config get [Options] --input <INPUT>
3131
cat <FILE> | dsc config get [Options] --file -
3232
```
3333

34+
### Configuration document from file with parameters from stdin
35+
36+
```sh
37+
cat <PARAMETERS_FILE> | dsc config --parameters-file - get [Options] --file <FILE>
38+
```
39+
40+
### Configuration document from option string with parameters from stdin
41+
42+
```sh
43+
cat <PARAMETERS_FILE> | dsc config --parameters-file - get [Options] --input <INPUT>
44+
```
45+
3446
## Description
3547

3648
The `get` subcommand returns the actual state of the resource instances in a configuration

docs/reference/cli/config/index.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,6 +78,11 @@ for that parameter.
7878

7979
This option is mutually exclusive with the `--parameters` option.
8080

81+
Starting with DSC version 3.1.0, you can pass the parameters data to a subcommand over stdin. When
82+
you do, you must pass the configuration document as an input string or the path to a file on the
83+
system. You can't pass both the parameters file and the configuration document to a command from
84+
stdin.
85+
8186
For more information about defining parameters in a configuration document, see
8287
[DSC Configuration document parameter schema][06]. For more information about using parameters in
8388
configuration document, see the [parameters function reference][07].

docs/reference/cli/config/set.md

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,19 @@ dsc config set [Options] --input <INPUT>
3131
cat <FILE> | dsc config set [Options] --file -
3232
```
3333

34+
### Configuration document from file with parameters from stdin
35+
36+
```sh
37+
cat <PARAMETERS_FILE> | dsc config --parameters-file - set [Options] --file <FILE>
38+
```
39+
40+
### Configuration document from option string with parameters from stdin
41+
42+
```sh
43+
cat <PARAMETERS_FILE> | dsc config --parameters-file - set [Options] --input <INPUT>
44+
```
45+
46+
3447
## Description
3548

3649
The `set` subcommand enforces the desired state of the resource instances in a configuration

0 commit comments

Comments
 (0)