Examples/Resources/AdcsCertificationAuthority/1-AdcsCertificationAuthority_InstallCertificationAthority_Config.ps1
<#PSScriptInfo
.VERSION 1.0.0 .GUID 3dc7df43-9264-411d-9596-36e780725b4e .AUTHOR Microsoft Corporation .COMPANYNAME Microsoft Corporation .COPYRIGHT .TAGS DSCConfiguration .LICENSEURI https://github.com/PowerShell/ActiveDirectoryCSDsc/blob/master/LICENSE .PROJECTURI https://github.com/PowerShell/ActiveDirectoryCSDsc .ICONURI .EXTERNALMODULEDEPENDENCIES .REQUIREDSCRIPTS .EXTERNALSCRIPTDEPENDENCIES .RELEASENOTES First version. .PRIVATEDATA 2016-Datacenter,2016-Datacenter-Server-Core #> #Requires -module ActiveDirectoryCSDsc <# .DESCRIPTION This example will add the Active Directory Certificate Services Certificate Authority feature to a server and configure it as a certificate authority enterprise root CA. #> Configuration AdcsCertificationAuthority_InstallCertificationAthority_Config { param ( [Parameter(Mandatory = $true)] [ValidateNotNullorEmpty()] [System.Management.Automation.PSCredential] $Credential ) Import-DscResource -Module ActiveDirectoryCSDsc Node localhost { WindowsFeature ADCS-Cert-Authority { Ensure = 'Present' Name = 'ADCS-Cert-Authority' } AdcsCertificationAuthority CertificateAuthority { IsSingleInstance = 'Yes' Ensure = 'Present' Credential = $Credential CAType = 'EnterpriseRootCA' DependsOn = '[WindowsFeature]ADCS-Cert-Authority' } } } |