This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[DSCLocalConfigurationManager()] | |
configuration LcmDebugConfig | |
{ | |
Node localhost | |
{ | |
Settings | |
{ | |
RefreshMode = 'Push' | |
DebugMode = 'ForceModuleImport' | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
trigger: | |
- '*' | |
stages: | |
- stage: develop | |
jobs: | |
- job: A | |
strategy: | |
parallel: 4 | |
pool: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Get-Enum | |
{ | |
param ( | |
[type]$Type | |
) | |
[enum]::GetValues($Type) | | |
Select-Object -Property ` | |
@{ Name = 'Name'; Expression={ [string]$_ } }, | |
@{ Name = 'Value'; Expression={ [int]$_ }}, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Get-Test | |
{ | |
Get-Date | |
} | |
function New-TestRole | |
{ | |
New-PSRoleCapabilityFile -Path c:\TestRole.psrc ` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#usually the process consuming the most memory is the one that hosts the LCM | |
$p = Get-Process -Name WmiPrvSE | Sort-Object -Property WS -Descending | Select-Object -First 1 | |
Enter-PSHostProcess -Process $p -AppDomainName DscPsPluginWkr_AppDomain | |
Start-Sleep -Seconds 1 | |
$rs = Get-Runspace | Where-Object { $_.Debugger.InBreakpoint } | |
Debug-Runspace -Runspace $rs |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?xml version="1.0" encoding="utf-8" ?> | |
<Configuration> | |
<ViewDefinitions> | |
<View> | |
<Name>Microsoft.PowerShell.Commands.GenericMeasureInfo</Name> | |
<ViewSelectedBy> | |
<TypeName>Microsoft.PowerShell.Commands.GenericMeasureInfo</TypeName> | |
</ViewSelectedBy> | |
<ListControl> | |
<ListEntries> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$types = @' | |
using System; | |
namespace Kerberos | |
{ | |
public enum EncryptionTypes:uint | |
{ | |
AES256_CTS_HMAC_SHA1_96 = 18, | |
AES128_CTS_HMAC_SHA1_96 = 17, | |
ARCFOUR_HMAC_MD5 = 23, |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Connect-SupportSession | |
{ | |
param( | |
[Parameter(Mandatory)] | |
[string]$ComputerName, | |
[pscredential]$Credential | |
) | |
$s = New-PSSession @PSBoundParameters -ConfigurationName Support #-ErrorAction SilentlyContinue |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function Unlock-AAAccount | |
{ | |
param( | |
[Parameter(Mandatory)] | |
[string]$Identity | |
) | |
try | |
{ | |
$user = Get-ADUser -Identity $Identity |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
param( | |
[Parameter(Mandatory)] | |
[string]$Path | |
) | |
#Created by Pierre.Audonnet@microsoft.com | |
# | |
#Got keytab structure from http://www.ioplex.com/utilities/keytab.txt | |
# | |
# keytab { |