Skip to content

Commit a6e3023

Browse files
authored
Merge pull request #11959 from MicrosoftDocs/main
3/26/2025 PM Publish
2 parents 11eabae + d8feba0 commit a6e3023

File tree

8 files changed

+309
-254
lines changed

8 files changed

+309
-254
lines changed

reference/5.1/Microsoft.PowerShell.Core/About/about_Parameter_Sets.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to define and use parameter sets in advanced functions.
33
Locale: en-US
4-
ms.date: 03/27/2024
4+
ms.date: 03/26/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_parameter_sets?view=powershell-5.1&WT.mc_id=ps-gethelp
66
title: about_Parameter_Sets
77
---
@@ -64,12 +64,23 @@ one unique parameter.
6464
Parameters that don't have an assigned parameter set name belong to all
6565
parameter sets.
6666

67+
## Reserved parameter set name
68+
69+
PowerShell reserves the parameter set name `__AllParameterSets` for special
70+
handling.
71+
72+
- This name is the default name of the parameter set that when you don't
73+
explicitly define a parameter set name.
74+
- When you have muliple parameter sets, you can use this name to define a
75+
parameter that belongs to all parameter sets.
76+
- Setting **DefaultParameterSetName** to `__AllParameterSets` in the
77+
`[CmdletBinding()]` attribute has no effect.
78+
6779
## Examples
6880

6981
The following example function counts the number lines, characters, and words
70-
in a text file. Using parameters, you can specify which values you want
71-
returned and which files you want to measure. There are four parameter sets
72-
defined:
82+
in a text file. Using parameters, you can specify the values you want returned
83+
and the files you want to measure. There are four parameter sets defined:
7384

7485
- Path
7586
- PathAll

reference/5.1/Microsoft.PowerShell.Management/Test-ComputerSecureChannel.md

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,11 @@ more detailed test results, use the **Verbose** parameter.
3434
This cmdlet works much like `NetDom.exe`. Both NetDom and `Test-ComputerSecureChannel` use the
3535
**NetLogon** service to perform the actions.
3636

37+
> [!NOTE]
38+
> This cmdlet only works on Domain Member computers. When you run it on Domain Controllers, it
39+
> returns false positive errors. To verify and reset the secure channels for Domain Controllers,
40+
> use `netdom.exe` or `nltest.exe`.
41+
3742
## EXAMPLES
3843

3944
### Example 1: Test a channel between the local computer and its domain
@@ -74,7 +79,8 @@ VERBOSE: "The secure channel between 'SERVER01' and 'net.fabrikam.com' is alive
7479
```
7580

7681
This command uses the **Verbose** common parameter to request detailed messages about the operation.
77-
For more information about **Verbose**, see [about_CommonParameters](../Microsoft.PowerShell.Core/About/about_CommonParameters.md).
82+
For more information about **Verbose**, see
83+
[about_CommonParameters](../Microsoft.PowerShell.Core/About/about_CommonParameters.md).
7884

7985
### Example 5: Test a connection before you run a script
8086

@@ -170,7 +176,7 @@ Accept wildcard characters: False
170176
171177
### -WhatIf
172178
173-
Shows what would happen if the cmdlet runs. The cmdlet is not run.
179+
Shows what would happen if the cmdlet runs. The cmdlet isn't run.
174180
175181
```yaml
176182
Type: System.Management.Automation.SwitchParameter
@@ -188,7 +194,8 @@ Accept wildcard characters: False
188194
189195
This cmdlet supports the common parameters: -Debug, -ErrorAction, -ErrorVariable,
190196
-InformationAction, -InformationVariable, -OutVariable, -OutBuffer, -PipelineVariable, -Verbose,
191-
-WarningAction, and -WarningVariable. For more information, see [about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).
197+
-WarningAction, and -WarningVariable. For more information, see
198+
[about_CommonParameters](https://go.microsoft.com/fwlink/?LinkID=113216).
192199
193200
## INPUTS
194201
@@ -218,3 +225,7 @@ This cmdlet returns `$true` if the connection is working correctly and `$false`
218225
[Restart-Computer](Restart-Computer.md)
219226

220227
[Stop-Computer](Stop-Computer.md)
228+
229+
[Use Netdom.exe to reset machine account passwords of a Windows Server domain controller](/troubleshoot/windows-server/windows-security/use-netdom-reset-domain-controller-password)
230+
231+
[Nltest.exe](/previous-versions/windows/it-pro/windows-server-2012-r2-and-2012/cc731935(v=ws.11))

reference/7.4/Microsoft.PowerShell.Core/About/about_Parameter_Sets.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to define and use parameter sets in advanced functions.
33
Locale: en-US
4-
ms.date: 03/27/2024
4+
ms.date: 03/26/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_parameter_sets?view=powershell-7.4&WT.mc_id=ps-gethelp
66
title: about_Parameter_Sets
77
---
@@ -64,12 +64,23 @@ one unique parameter.
6464
Parameters that don't have an assigned parameter set name belong to all
6565
parameter sets.
6666

67+
## Reserved parameter set name
68+
69+
PowerShell reserves the parameter set name `__AllParameterSets` for special
70+
handling.
71+
72+
- This name is the default name of the parameter set that when you don't
73+
explicitly define a parameter set name.
74+
- When you have muliple parameter sets, you can use this name to define a
75+
parameter that belongs to all parameter sets.
76+
- Setting **DefaultParameterSetName** to `__AllParameterSets` in the
77+
`[CmdletBinding()]` attribute has no effect.
78+
6779
## Examples
6880

6981
The following example function counts the number lines, characters, and words
70-
in a text file. Using parameters, you can specify which values you want
71-
returned and which files you want to measure. There are four parameter sets
72-
defined:
82+
in a text file. Using parameters, you can specify the values you want returned
83+
and the files you want to measure. There are four parameter sets defined:
7384

7485
- Path
7586
- PathAll

reference/7.5/Microsoft.PowerShell.Core/About/about_Parameter_Sets.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to define and use parameter sets in advanced functions.
33
Locale: en-US
4-
ms.date: 03/27/2024
4+
ms.date: 03/26/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_parameter_sets?view=powershell-7.5&WT.mc_id=ps-gethelp
66
title: about_Parameter_Sets
77
---
@@ -64,12 +64,23 @@ one unique parameter.
6464
Parameters that don't have an assigned parameter set name belong to all
6565
parameter sets.
6666

67+
## Reserved parameter set name
68+
69+
PowerShell reserves the parameter set name `__AllParameterSets` for special
70+
handling.
71+
72+
- This name is the default name of the parameter set that when you don't
73+
explicitly define a parameter set name.
74+
- When you have muliple parameter sets, you can use this name to define a
75+
parameter that belongs to all parameter sets.
76+
- Setting **DefaultParameterSetName** to `__AllParameterSets` in the
77+
`[CmdletBinding()]` attribute has no effect.
78+
6779
## Examples
6880

6981
The following example function counts the number lines, characters, and words
70-
in a text file. Using parameters, you can specify which values you want
71-
returned and which files you want to measure. There are four parameter sets
72-
defined:
82+
in a text file. Using parameters, you can specify the values you want returned
83+
and the files you want to measure. There are four parameter sets defined:
7384

7485
- Path
7586
- PathAll

reference/7.6/Microsoft.PowerShell.Core/About/about_Parameter_Sets.md

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to define and use parameter sets in advanced functions.
33
Locale: en-US
4-
ms.date: 03/27/2024
4+
ms.date: 03/26/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_parameter_sets?view=powershell-7.6&WT.mc_id=ps-gethelp
66
title: about_Parameter_Sets
77
---
@@ -64,12 +64,23 @@ one unique parameter.
6464
Parameters that don't have an assigned parameter set name belong to all
6565
parameter sets.
6666

67+
## Reserved parameter set name
68+
69+
PowerShell reserves the parameter set name `__AllParameterSets` for special
70+
handling.
71+
72+
- This name is the default name of the parameter set that when you don't
73+
explicitly define a parameter set name.
74+
- When you have muliple parameter sets, you can use this name to define a
75+
parameter that belongs to all parameter sets.
76+
- Setting **DefaultParameterSetName** to `__AllParameterSets` in the
77+
`[CmdletBinding()]` attribute has no effect.
78+
6779
## Examples
6880

6981
The following example function counts the number lines, characters, and words
70-
in a text file. Using parameters, you can specify which values you want
71-
returned and which files you want to measure. There are four parameter sets
72-
defined:
82+
in a text file. Using parameters, you can specify the values you want returned
83+
and the files you want to measure. There are four parameter sets defined:
7384

7485
- Path
7586
- PathAll
Lines changed: 45 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -1,83 +1,72 @@
11
---
2-
description: How to use PowerShell that's preinstalled in a Docker image.
3-
ms.date: 08/01/2024
2+
description: How to use PowerShell in a Docker image.
3+
ms.date: 03/11/2025
44
ms.devlang: powershell
55
ms.topic: conceptual
6-
title: Using PowerShell in Docker
6+
title: Use PowerShell in Docker
77
---
88

9-
# Using PowerShell in Docker
9+
# Use PowerShell in Docker
1010

11-
We publish Docker images with PowerShell preinstalled. This article shows you how to get
12-
started using PowerShell in the Docker container.
11+
The .NET team publishes Docker images with PowerShell preinstalled. This article shows you how to
12+
get started using PowerShell in the Docker container.
1313

14-
## Finding available images
14+
## Find available images
1515

16-
The released images require Docker 17.05 or newer. It's also expected that you are able to run
17-
Docker without `sudo` or local administrative rights. Please follow Docker's official
18-
[instructions][01] to install `docker` correctly.
16+
These images require Docker 17.05 or newer. Also, you must be able to run Docker without `sudo` or
17+
local administrative rights. For install instructions, see Docker's official [documentation][02].
1918

20-
The release containers derive from the official distribution image, then install dependencies, and
21-
finally install the PowerShell package.
19+
The .NET team publishes several Docker images designed for different development scenarios. Only the
20+
image for the .NET SDK contains PowerShell. For more information, see
21+
[Official .NET Docker images][01].
2222

23-
These containers live at [Microsoft Artifact Registry][05].
23+
## Use PowerShell in a container
2424

25-
For more information about these Docker images, visit the [PowerShell-Docker][02] repository on
26-
GitHub.
27-
28-
## Using PowerShell in a container
29-
30-
The following steps show the Docker commands required to download the image containing the latest
31-
available stable version of PowerShell and start an interactive PowerShell session.
25+
The following command downloads the image containing the latest available stable versions of the
26+
.NET SDK and PowerShell.
3227

3328
```console
34-
docker run -it mcr.microsoft.com/powershell
29+
docker pull mcr.microsoft.com/dotnet/sdk:9.0
3530
```
3631

37-
Use the following command to download and run the image containing the latest available preview
38-
version of PowerShell.
39-
40-
```console
41-
docker run -it mcr.microsoft.com/powershell:preview
42-
```
43-
> [!IMPORTANT]
44-
> The Docker images are built from official operating system (OS) images provide by the OS
45-
> distributor. These images may not have the latest security updates. Microsoft recommends that you
46-
> update the OS packages to the latest version to ensure the latest security updates are applied.
47-
48-
### Remove the image when no longer needed
49-
50-
The following command is used to delete the Docker image when you no longer need it.
32+
Use the following command to start an interactive PowerShell session in the container.
5133

5234
```console
53-
docker rmi mcr.microsoft.com/powershell
35+
docker run -it mcr.microsoft.com/dotnet/sdk:9.0 pwsh
5436
```
5537

56-
## Legal and Licensing
38+
To download and run the latest Long Term Support (LTS) version of PowerShell, change the image name
39+
to `mcr.microsoft.com/dotnet/sdk:8.0`. When you use these image tags, Docker downloads the
40+
appropriate image for your host operating system. If you want an image for a specific operating
41+
system, you can specify the operating system in the image tag. See the
42+
[Microsoft Artifact Registry][07] for a list of available tags.
5743

58-
PowerShell is licensed under the [MIT license][03].
44+
- For more information about tags, the [Supported tag policy][06]
45+
- For more information about supported operating systems, see the [Supported platforms policy][05]
5946

60-
### Windows Docker file and image licenses
47+
## Support lifecycle
6148

62-
By requesting and using the Container OS Image for Windows containers, you acknowledge, understand,
63-
and consent to the Supplemental License Terms available on Docker hub:
49+
The [.NET support policy][03] defines how these images are supported. These images are provided for
50+
development and testing purposes only. If you need a production-ready image, you should build your
51+
own images. For more information about these Docker images, visit the [dotnet-docker][04] repository
52+
on GitHub.
6453

65-
- [Window Server Core][06]
66-
- [Nano Server][04]
54+
The images previously published by the PowerShell team will be marked as deprecated in the Microsoft
55+
Container Registry (MCR).
6756

68-
### Telemetry
57+
## Telemetry
6958

70-
By default, PowerShell collects limited telemetry without personally identifiable information to
71-
help aid development of future versions of PowerShell. To opt-out of sending telemetry, create an
72-
environment variable called `POWERSHELL_TELEMETRY_OPTOUT` set to a value of `1` before starting
73-
PowerShell from the installed location. The telemetry we collect falls under the
74-
[Microsoft Privacy Statement][07].
59+
By default, PowerShell collects limited telemetry without personal data to help aid development of
60+
future versions of PowerShell. To opt-out of sending telemetry, create an environment variable
61+
called `POWERSHELL_TELEMETRY_OPTOUT` set to a value of `1` before starting PowerShell from the
62+
installed location. The telemetry we collect falls under the [Microsoft Privacy Statement][08].
7563

7664
<!-- link references -->
77-
[01]: https://docs.docker.com/engine/installation/
78-
[02]: https://github.com/PowerShell/PowerShell-Docker
79-
[03]: https://github.com/PowerShell/PowerShell/tree/master/LICENSE.txt
80-
[04]: https://mcr.microsoft.com/product/windows/nanoserver
81-
[05]: https://mcr.microsoft.com/product/powershell
82-
[06]: https://mcr.microsoft.com/product/windows/servercore
83-
[07]: https://privacy.microsoft.com/privacystatement/
65+
[01]: /dotnet/architecture/microservices/net-core-net-framework-containers/official-net-docker-images
66+
[02]: https://docs.docker.com/engine/installation/
67+
[03]: https://github.com/dotnet/core/blob/main/support.md
68+
[04]: https://github.com/dotnet/dotnet-docker
69+
[05]: https://github.com/dotnet/dotnet-docker/blob/main/documentation/supported-platforms.md
70+
[06]: https://github.com/dotnet/dotnet-docker/blob/main/documentation/supported-tags.md
71+
[07]: https://mcr.microsoft.com/en-us/artifact/mar/dotnet/sdk/about
72+
[08]: https://privacy.microsoft.com/privacystatement/

reference/docs-conceptual/learn/ps101/06-flow-control.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -313,7 +313,7 @@ In this chapter, you learned about the different types of loops that exist in Po
313313

314314
## References
315315

316-
- [ForEach-Object][ForEach-Object]
316+
- [ForEach-Object][foreach-object]
317317
- [about_Foreach][about-foreach]
318318
- [about_For][about-for]
319319
- [about_Do][about-do]

0 commit comments

Comments
 (0)