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
{ | |
"EngineConfiguration": { | |
"PollInterval": "00:00:15", | |
"Components": [ | |
{ | |
"Id": "MemoryCounter", | |
"FullName": "AWS.EC2.Windows.CloudWatch.PerformanceCounterComponent.PerformanceCounterInputComponent,AWS.EC2.Windows.CloudWatch", | |
"Parameters": { | |
"CategoryName": "Memory", | |
"CounterName": "Available MBytes", |
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
{ | |
"Description": "This one is to create roles required for CodeDeploy", | |
"AWSTemplateFormatVersion": "2010-09-09", | |
"Resources": { | |
"CodeDeployTrustRole": { | |
"Type": "AWS::IAM::Role", | |
"Properties": { | |
"AssumeRolePolicyDocument": { | |
"Statement": [ |
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
<# | |
.NOTES | |
=========================================================================== | |
Created on: Jan 2017 | |
Created by: Dmitriy Kagarlickij | |
Contact: dmitriy@kagarlickij.com | |
=========================================================================== | |
.DESCRIPTION | |
This script should be executing with Administrator-level permissions | |
#> |
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
$adapters=(gwmi win32_networkadapterconfiguration ) | |
Foreach ($adapter in $adapters){ | |
Write-Host $adapter | |
$adapter.settcpipnetbios(2) | |
} |
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
# Set default minimal RAM in Mb | |
$DefaultMinimalRAM = 512 | |
# Set default minimal HDD in Gb | |
$DefaultMinimalHDD = 20 | |
# Set function | |
function HardwareCheck { | |
# Set parameters |
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
$From = "dmitriy@kagarlickij.com" | |
$To = "noreply@kagarlickij.com" | |
$Subject = "Test email from $hostname on $date" | |
$body = "Running on $hostname $date" | |
$Body += "<br>" | |
$Body += "<b><font color=green>Test</b></font> <br>" | |
$SMTPServer = "smtp.gmail.com" | |
$SMTPPort = "587" |
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
<# | |
.NOTES | |
=========================================================================== | |
Created with: SAPIEN Technologies, Inc., PowerShell Studio 2016 v5.2.117 | |
Created on: 17.03.2016 | |
Created by: Dmitriy Kagarlickij | |
Contact: dmitriy@kagarlickij.com | |
=========================================================================== | |
.DESCRIPTION | |
This script should be executing with Administrator-level permissions |
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
# Using PowerShell | |
Get-Service | Where-Object {$_.StartType -eq 'Auto' -and $_.Status -ne 'Running'} | |
# Using WMI | |
Get-WmiObject Win32_Service | Where-Object {$_.StartMode -eq 'Auto' -and $_.Status -ne 'OK'} |
NewerOlder