There are multiple ways to install DSC v3.
Select the tab for the desired platform to see the detailed installation instructions.
Install DSC using WinGet
The following commands can be used to install DSC using the published winget packages.
Search for the latest version of DSC:
winget search DesiredStateConfiguration --source msstore
Name Id Version Source
---------------------------------------------------------------
DesiredStateConfiguration 9NVTPZWRC6KQ Unknown msstore
DesiredStateConfiguration-Preview 9PCX3HX4HZ0Z Unknown msstore
Install DSC using the id parameter:
# Install latest stable
winget install --id 9NVTPZWRC6KQ --source msstore
# Install latest preview
winget install --id 9PCX3HX4HZ0Z --source msstore
Install DSC from the .zip file
Download the latest release from the DSC repository for your processor type:
Unzip the package to a folder:
Expand-Archive -Path .\DSC-3.3.0-rc.2-x86_64-pc-windows-msvc.zip -DestinationPath C:\DSC
Add the DSC folder to your system PATH environment variable.
Install DSC from the Microsoft package repository
Note
This script only works for supported versions of Debian that have a package published to the
Microsoft package repository. For other versions of Debian, use the manual installation method.
#!/bin/bash
###################################
# Prerequisites
# Update and install the pre-requisite packages.
sudo apt-get install -y wget apt-transport-https software-properties-common
# Download the Microsoft repository keys for your version of Ubuntu
source /etc/os-release
wget -q https://packages.microsoft.com/config/debian/$VERSION_ID/packages-microsoft-prod.deb
# Register the Microsoft repository keys
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
# Update the list of packages and install DSC
sudo apt-get update
sudo apt-get install -y dsc
Manually install DSC from the DEB package
Download the universal package from the GitHub releases page for your processor architecture.
The following shell script downloads and installs the current release of DSC. You can change the URL
to download the version of DSC that you want to install.
#!/bin/bash
###################################
# Prerequisites
# Update and install the pre-requisite packages.
sudo apt-get update
sudo apt-get install -y wget
# Download the DSC package file
wget https://github.com/PowerShell/DSC/releases/download/v3.3.0-rc.2/dsc_3.3.0-rc.2-1_amd64.deb
# Install the DSC package
sudo dpkg -i dsc_3.3.0-rc.2-1_amd64.deb
rm dsc_3.3.0-rc.2-1_amd64.deb
Install DSC from the Microsoft package repository
Note
This script only works for supported versions of Ubuntu that have a package published to the
Microsoft package repository. For other versions of Ubuntu, use the manual installation method.
#!/bin/bash
###################################
# Prerequisites
# Update and install the pre-requisite packages.
sudo apt-get install -y wget apt-transport-https software-properties-common
# Download the Microsoft repository keys for your version of Debian
source /etc/os-release
wget -q https://packages.microsoft.com/config/ubuntu/$VERSION_ID/packages-microsoft-prod.deb
# Register the Microsoft repository keys
sudo dpkg -i packages-microsoft-prod.deb
rm packages-microsoft-prod.deb
# Update the list of packages and install DSC
sudo apt-get update
sudo apt-get install -y dsc
Manually install DSC from the DEB package
Download the universal package from the GitHub releases page for your processor architecture.
The following shell script downloads and installs the current release of DSC. You can change the URL
to download the version of DSC that you want to install.
#!/bin/bash
###################################
# Prerequisites
# Update and install the pre-requisite packages.
sudo apt-get update
sudo apt-get install -y wget
# Download the DSC package file
wget https://github.com/PowerShell/DSC/releases/download/v3.3.0-rc.2/dsc_3.3.0-rc.2-1_amd64.deb
# Install the DSC package
sudo dpkg -i dsc_3.3.0-rc.2-1_amd64.deb
rm dsc_3.3.0-rc.2-1_amd64.deb
Install DSC from the Microsoft package repository
Note
This script only works for supported versions of RHEL that have a package published to the
Microsoft package repository. For other supported versions of RHEL, use the manual installation
method.
#!/bin/bash
###################################
# Get version of RHEL
source /etc/os-release
majorver=${VERSION_ID%.*}
# Download and register the Microsoft Red Hat repository package
curl -sSL -O https://packages.microsoft.com/config/rhel/$majorver/packages-microsoft-prod.rpm
sudo rpm -i packages-microsoft-prod.rpm
rm packages-microsoft-prod.rpm
# Update package index files
sudo dnf update
# Install DSC
sudo dnf install dsc -y
Manually install DSC from the RPM package
Download the universal package from the GitHub releases page for your processor architecture.
The following shell script downloads and installs the current release of DSC. You can change the URL
to download the version of DSC that you want to install.
sudo dnf install https://github.com/PowerShell/DSC/releases/download/v3.3.0-rc.2/dsc-3.3.0.rc.2-1.x86_64.rpm
Manually install DSC from the .tar.gz package
Download the macOS package from the GitHub releases page for your processor architecture.
The following shell script downloads and installs the current release of DSC. You can change the URL
to download the version of DSC that you want to install.
curl -sSL -O https://github.com/PowerShell/DSC/releases/download/v3.3.0-rc.2/DSC-3.3.0-rc.2-aarch64-apple-darwin.tar.gz
Create a new folder and extract files to that folder:
mkdir -p ~/.local/share/dsc
tar -xzf ./dsc-3.3.0-rc.2-aarch64-apple-darwin.tar.gz -C ~/.local/share/dsc
Add the new folder to your PATH environment variable.