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
### Keybase proof | |
I hereby claim: | |
* I am jhmartin on github. | |
* I am toger (https://keybase.io/toger) on keybase. | |
* I have a public key whose fingerprint is C79F 0853 C15A C7E9 E798 C97E D81C 9326 A979 840A | |
To claim this, I am signing this object: |
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
To search the node api, filtering by role:manager | |
http://127.0.0.1:2375/nodes?filters=%7B%22role%22%3A%5B%22manager%22%5D%7D | |
Filters= is the URLEncoded version of {"role":["manager"]} |
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
{ | |
"AWSTemplateFormatVersion": "2010-09-09", | |
"Metadata": { | |
"AWS::CloudFormation::Designer": { | |
"f700037a-b1cd-40cc-968f-c67ea5a2d96f": { | |
"size": { | |
"width": 60, | |
"height": 60 | |
}, | |
"position": { |
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
import javax.net.ssl.SSLSocket; | |
import javax.net.ssl.SSLSocketFactory; | |
import java.io.*; | |
/** Establish a SSL connection to a host and port, writes a byte and | |
* prints the response. See | |
* http://confluence.atlassian.com/display/JIRA/Connecting+to+SSL+services | |
*/ | |
public class SSLPoke { | |
public static void main(String[] args) { |
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
if (request.type == 'LAUNCH_REQUEST') | |
# Process your Launch Request | |
# Call your methods for your application here that process your Launch Request. | |
response.add_speech('House Control online') | |
response.add_hash_card( { :title => 'My House', :subtitle => 'House Control activated.' } ) | |
end | |
if (request.type == 'INTENT_REQUEST') | |
# Process your Intent Request | |
p "#{request.slots['helper']['value']}" |
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
// Based on https://github.com/noelportugal/AmazonEchoApi.git, watches for 'goodnight' and sets a Z-Way scene. | |
public static void main(String[] args) throws InterruptedException, IOException { | |
AmazonEchoApi amazonEchoApi = new AmazonEchoApi("https://pitangui.amazon.com","[email protected]", "SNIP"); | |
if (amazonEchoApi.httpLogin()){ | |
while (true) { | |
String output = amazonEchoApi.httpGet("/api/cards?type=TASK&size=1"); | |
//String output = amazonEchoApi.httpGet("/api/cards?type=TASK&size=1"); | |
//String output = amazonEchoApi.httpGet("/api/todos?type=TASK&size=1"); | |
// Parse JSON |
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
#http://pastebin.com/xGt6vv9R from yardenbar | |
output { | |
if [type] == "postfix" { | |
elasticsearch { | |
host => [ "ES_HOSTNAME" ] | |
protocol => "transport" | |
cluster => "elasticsearch" | |
index => "postfix-%{+YYYY.MM.dd}" | |
manage_template => true | |
template_overwrite => true |
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
### Keybase proof | |
I hereby claim: | |
* I am jhmartin on github. | |
* I am toger (https://keybase.io/toger) on keybase. | |
* I have a public key whose fingerprint is 295E 910B 42C5 3CE3 683C CD17 B1E3 6C1C E754 A822 | |
To claim this, I am signing this object: |
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
curl -v -X POST http://localhost:8080/v2/apps \ | |
-H Content-Type:application/json -d '{ | |
"id": "some-nginx", | |
"container": { | |
"docker": { | |
"parameters" : { | |
"env": "SERVICE_NAME=nginx-xyz" | |
}, | |
"image": "nginx", | |
"network": "BRIDGE", |
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
$ /opt/chef/embedded/bin/sensu-cli client history XYZ | |
------- | |
check: sensu-redis-metrics | |
history: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] | |
last_execution: 1413319524 | |
last_status: 0 | |
------- | |
check: check-aws-maintenance | |
history: [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0] | |
last_execution: 1413319467 |