- Setup Golang.
- Install gox for cross platform compilation:
go get -u github.com/mitchellh/gox
This file contains hidden or 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
| $n = "hello" | |
| $p = "`$$($n) = `"goodbye`"" | |
| Invoke-Expression $p |
This file contains hidden or 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
| #PEM Key for password decrypt | |
| $PEM = "$HOME\MyKey.pem" | |
| $KeyName = "MyKey" | |
| #EC2 Bootstrap | |
| $EC2UserData = Get-Content "$HOME\ec2-user-data.ps1" | |
| #Userdata has to be base64 encoded | |
| $EC2UserDataBase64Encoded = [System.Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($EC2UserData)) | |
This file contains hidden or 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
| [ | |
| { | |
| "keys": ["ctrl+alt+f"], | |
| "args": { | |
| "id": "repl_f#", | |
| "file": "config/F/Main.sublime-menu" | |
| }, | |
| "command": "run_existing_window_command" | |
| }, | |
| { |
This file contains hidden or 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
| { | |
| "tab_size": 4, | |
| "convert_tabs_to_spaces": true | |
| } |
This file contains hidden or 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
| { | |
| "clusterName": "MyCluster", | |
| "datacenterName": "Melbourne", | |
| "hostName": "esxihost.localnet", | |
| "ESXusernameText": "root", | |
| "ESXpasswordText": "password", | |
| "user": "packer", | |
| "password": "password", | |
| "vm_nameText": "PackerTemplateWin2012R2", | |
| "vm_networkName": "VM Network", |
This file contains hidden or 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
| { | |
| "variables": { | |
| "clusterName": "", | |
| "datacenterName": "", | |
| "hostName": "", | |
| "ESXusernameText": "", | |
| "ESXpasswordText": "", | |
| "user": "", | |
| "password": "", | |
| "vm_nameText": "", |
This file contains hidden or 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
| #Configure NIC as Env has no DHCP | |
| $netadapter = Get-NetAdapter -Name Ethernet | |
| ## Disable DHCP | |
| $netadapter | Set-NetIPInterface -DHCP Disabled | |
| ## Configure the IP address and default gateway for "VM Network" in Env | |
| $netadapter | New-NetIPAddress -AddressFamily IPv4 -IPAddress 10.1.0.250 -PrefixLength 24 -Type Unicast -DefaultGateway 10.1.0.254 | |
| ## Configure the DNS servers | |
| Set-DnsClientServerAddress -InterfaceAlias Ethernet -ServerAddresses ("172.1.0.2","172.1.0.3”) |
This file contains hidden or 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
| for f in *_*; do echo mv "${f}" "${f//_/-}"; done | |
| for f in *_*; do echo mv "${f}" "NewPrefix${f/OldPrefix/}"; done |
This file contains hidden or 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
| { | |
| "variables": { | |
| "vcenter": "", | |
| "clusterName": "", | |
| "datacenterName": "", | |
| "hostName": "", | |
| "ESXusernameText": "", | |
| "ESXpasswordText": "", | |
| "user": "", | |
| "password": "", |