Skip to content

Instantly share code, notes, and snippets.

//************* Wol Clock by Jon Fuge ******************************
// https://www.instructables.com/id/Wol-Clock-ESP8266-12E-60-LED-WS2812B-Analogue-Digi/
//************* Declare included libraries ******************************
#include <NTPClient.h>
#include <Time.h>
#include <TimeLib.h>
#include <Adafruit_NeoPixel.h>
#include <ESP8266WiFi.h>
#include <WiFiUdp.h>
#include <Timezone.h> // https://github.com/JChristensen/Timezone
Get-Module –ListAvailable VM* | Import-Module -ErrorAction SilentlyContinue
Set-PowerCLIConfiguration -DefaultVIServerMode Multiple -Confirm:$false
# Make sure no vcenters are connected that dont need to be.
if ($global:DefaultVIServer.IsConnected -eq $true){
write-host "We have vcenters still connected, disconnecting....." -ForegroundColor Red
Disconnect-VIServer * -Confirm:$false
}
<TaskerData sr="" dvi="1" tv="4.9u4m">
<Profile sr="prof3" ve="2">
<cdate>1499507734147</cdate>
<edate>1499910853808</edate>
<id>3</id>
<mid0>7</mid0>
<mid1>9</mid1>
<nme>Home Occupancy</nme>
<State sr="con0" ve="2">
<code>160</code>
function log ([string]$logdata){
$logfile = "c:\temp\Cloudflare-dns.log"
$date = get-date
Write-Output "$date - $logdata" | Out-File $logfile -width 240 -Append
}
$headers = @{
'X-Auth-Key' = 'key';
'X-Auth-Email' = 'email';
@coza73
coza73 / TemplateMigrate.ps1
Last active August 29, 2015 14:05
Scipt to migrate selected templates from one virtualcenter to another
<#
NAME: MigrateTemplages.ps1
AUTHOR: Cory Murdoch
EMAIL: cory at coryandwendy dot com
BLOG: http://vspherepowershellscripts.blogspot.com
.SYNOPSIS
Scipt to migrate selected templates from one virtualcenter to another
@coza73
coza73 / vsphere_poweroff_vm_cluster.ps1
Last active August 29, 2015 14:03
vSphere power off all running VM's in a cluster
#############################################################################################
# Power off or on all running vm's in a cluster
# Script must be run from same place for power on to work properly
# It writes to file the names of all the powered on VM's, this is to not power on VM's that
# were previously powered off. It then checks for that file for the power on cycle.
#
# http://vspherepowershellscripts.blogspot.com.au/2014/07/power-onoff-all-running-virtual.html?view=classic
#
#################################################################################################
@coza73
coza73 / vsphere_add_storage.ps1
Last active August 29, 2015 14:03
vSphere add storage from list in CSV
########################################################################################################
#
# Powershell Script for vSphere
#
# Script to mass add storage to esxi host/cluster from data in CSV
#
# http://vspherepowershellscripts.blogspot.com.au/2014/07/vsphere-bulk-add-storage.html
########################################################################################################
if ( (Get-PSSnapin -Name VMware.VimAutomation.Core -ErrorAction SilentlyContinue) -eq $null )
@coza73
coza73 / vSphere_SysLogCollector_Shortcut.ps1
Last active August 29, 2015 14:03
Script for vSphere SysLog Collector. Uses IP address from directories created for each esxi host to do a DNS lookup and create shortcuts for those folders based on the returned DNS of the esxi host
########################################################################################################
#
# Powershell Script for vSphere Syslog Collector
#
# Uses IP address from directories created for each esxi host to do a DNS lookup and create shortcuts
# for for those folders based on the returned DNS of the esxi host
#
# http://vspherepowershellscripts.blogspot.com.au/2014/07/test.html
#
########################################################################################################