Skip to content

Instantly share code, notes, and snippets.

[CmdletBinding()]
param ()
function Install-DscPullServerPrerequisites {
[CmdletBinding()]
param ()
$result = Install-WindowsFeature Web-Server,DSC-Service -IncludeManagementTools:$true -Restart:$false
if ($result.RestartNeeded -ne "No") {
Write-Output "A reboot is needed to complete this operation. Please reboot before continuing."
}
}
[CmdletBinding()]
param ()
function Install-DscPullServerPrerequisites {
[CmdletBinding()]
param ()
# If NuGet isn’t installed, install it.
$localProvider = Get-PackageProvider -Name NuGet -ListAvailable -ErrorAction SilentlyContinue
$provider = Find-PackageProvider -Name NuGet
if ($localProvider -eq $null) {
@robv8r
robv8r / Install-DscPullServer.ps1
Created August 20, 2017 19:54
Entry Point to remaining Power Shell Scripts
.\Install-DscPullServerPrerequisites.ps1
.\Install-DscPullServerPSRepository.ps1
@robv8r
robv8r / 3-column-css-flexbox-layout.markdown
Created March 25, 2018 23:41
3-column CSS Flexbox layout
@robv8r
robv8r / Get-DockerImageTag
Last active August 21, 2018 12:53
Get all Docker Image with all Tags using Powershell
function Get-DockerImageTag {
[CmdletBinding()]
Param (
[Parameter()]
[string[]]
$ImageName
)
PROCESS {
Foreach($name in $ImageName) {
@robv8r
robv8r / docker_tags.sh
Last active November 3, 2023 14:11
List Docker Image Tags using bash
#!/usr/bin/env bash
# Gets all tags for a given docker image.
# Examples:
# retrieve all tags for a single library
# docker-tags "library/redis" | jq --raw-output '.[]'
# retrieve all tags for multiple libraries
$source = 'C:\Program Files'
$target = 'D:\Program Files'
mkdir $target
( Get-Item $source ).GetAccessControl('Access') | Set-Acl $target