Skip to content

Instantly share code, notes, and snippets.

View terraform_workshop_base_deployment.tf
// Every root module needs a terraform block
terraform {
// Anything after version 1.0.0 maintains backward compatibility
required_version = ">=1.0.0"
// Here we specify which providers Terraform should use, in this case the Elastic Cloud Provider, ec
required_providers {
/*
View 99-screen-rotation.sh
#!/bin/bash
/usr/lib/screen-rotator/rotate.py &
View screen-rotator.service
[Unit]
Description=Screen Rotation Service
After=network.target
[Service]
Type=simple
User=root
WorkingDirectory=/usr/lib/screen-rotator/
ExecStart=/usr/lib/screen-rotator/rotate.py &
ExecStop=killall rotate.py
View keybase.md

Keybase proof

I hereby claim:

  • I am deepybee on github.
  • I am deepybee (https://keybase.io/deepybee) on keybase.
  • I have a public key ASCL86Z8XYYRzZe097xeovRHoSUGVgvjyvIegs_yPQqe5wo

To claim this, I am signing this object:

View gist:857945f17773baa509ba
package { 'collectd':
ensure => $collectd::package_ensure,
name => $collectd::package_name,
require => Apt::Source['apt_repo_name'],
install_options => ['--force-yes'],
}
@deepybee
deepybee / es-cluster-health
Created Feb 12, 2015
Elasticsearch Cluster Health API output; curl -X GET localhost:9200/_cluster/health?pretty
View es-cluster-health
{
"cluster_name" : "foo",
"status" : "green",
"timed_out" : false,
"number_of_nodes" : 4,
"number_of_data_nodes" : 4,
"active_primary_shards" : 545,
"active_shards" : 2005,
"relocating_shards" : 0,
"initializing_shards" : 0,
@deepybee
deepybee / gist:868ceee880e44a32f6ad
Last active Aug 29, 2015
Network block of logstash-forwarder config
View gist:868ceee880e44a32f6ad
"network": {
"servers": [ "logstash1:5000", "logstash2:5000" ],
"ssl certificate": "/etc/pki/tls/certs/your_ssl.crt",
"ssl key": "/etc/pki/tls/private/your_ssl.key",
"ssl ca": "/etc/pki/tls/certs/your_ssl.crt",
"timeout": 15
},
View gist:1a76dc403cd429393632
[2014-12-19 15:36:52,379][DEBUG][action.search.type ] [esch4] [.marvel-2014.12.04][0], node[D4aHg90sSYa7zyIyq5i-Pw], [P], s[STARTED]: Failed to execute [org.elasticsearch.action.search.SearchRequest@5aa5bea7] lastShard [true]
org.elasticsearch.transport.RemoteTransportException: [esch2][inet[/10.252.46.162:9300]][indices:data/read/search[phase/query]]
Caused by: org.elasticsearch.search.SearchParseException: [.marvel-2014.12.04][0]: from[-1],size[-1]: Parse Failure [Failed to parse source [{"facets":{"0":{"date_histogram":{"key_field":"@timestamp","value_field":"message_stats.deliver_no_ack_details.rate","interval":"30s"},"global":true,"facet_filter":{"fquery":{"query":{"filtered":{"query":{"query_string":{"query":"tags:rabbit"}},"filter":{"bool":{"must":[{"range":{"@timestamp":{"from":1418999768332,"to":1419003368332}}}]}}}}}}}},"size":0}]]
at org.elasticsearch.search.SearchService.parseSource(SearchService.java:681)
at org.elasticsearch.search.SearchService.createContext(SearchService.java:537)
at
@deepybee
deepybee / collectd_logstash.conf
Created Oct 23, 2014
Logstash collectd config
View collectd_logstash.conf
# collectd config for logstash
input {
udp {
port => 25826
codec => 'collectd'
tags => 'collectd'
}
}
filter {
if [plugin] == 'nginx' {
View collectd_stats.json
{
"title": "Collectd Stats",
"services": {
"query": {
"list": {
"0": {
"query": "plugin:\"load\"",
"alias": "Load",
"color": "#7EB26D",
"id": 0,