
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
pull request from master |
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
#!/bin/bash | |
RED=`tput setaf 1` | |
RESET=`tput sgr0` | |
while read local_ref local_sha1 remote_ref remote_sha1 | |
do | |
if [[ "${remote_ref##refs/heads/}" =~ ^(master|deploy) ]]; then | |
echo "${RED}Do not push to ${remote_ref##refs/heads/} branch!!!${RESET}" | |
echo |
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
{ | |
"Images": [ | |
{ | |
"VirtualizationType": "hvm", | |
"Name": "ubuntu/images/hvm-ssd/ubuntu-trusty-14.04-amd64-server-20140927", | |
"Hypervisor": "xen", | |
"SriovNetSupport": "simple", | |
"ImageId": "ami-e74b60e6", | |
"State": "available", | |
"BlockDeviceMappings": [ |
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
var aws = require('aws-sdk'); | |
aws.config.update({region: 'ap-northeast-1'}); | |
var s3 = new aws.S3({apiVersion: '2006-03-01'}); | |
var autoscaling = new aws.AutoScaling({apiVersion: '2011-01-01'}); | |
exports.handler = function(event, context) { | |
console.log('Received event:', JSON.stringify(event, null, 2)); | |
var message = JSON.parse(event.Records[0].Sns.Message); | |
if (message.NewStateValue === 'ALARM') { |
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
[mysqld] | |
datadir=/fioa/mysql | |
user=mysql | |
max_connections = 1000 | |
thread_cache_size = 1000 | |
sort_buffer_size=2M | |
#innodb_buffer_pool_size = 27G | |
#innodb_buffer_pool_size = 27000M | |
innodb_buffer_pool_size = 28150M |
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
console.log('Loading event'); | |
var aws = require('aws-sdk'); | |
var s3 = new aws.S3({apiVersion: '2006-03-01'}); | |
var autoscaling = new aws.AutoScaling({apiVersion: '2011-01-01'}); | |
exports.handler = function(event, context) { | |
console.log('Received event:'); | |
console.log(event); | |
//console.log(typeof event.Subject); | |
if (event.hasOwnProperty('Message')) { |
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
#!/bin/sh | |
# | |
# chkconfig: 2345 55 25 | |
# Description: Nginx init.d script, put in /etc/init.d, chmod +x /etc/init.d/nginx | |
# For Debian, run: update-rc.d -f nginx defaults | |
# For CentOS, run: chkconfig --add nginx | |
# | |
### BEGIN INIT INFO | |
# Provides: nginx | |
# Required-Start: $all |
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
make[2]: Leaving directory `/usr/local/src/ruby-2.1.2/ext/sdbm' | |
make[2]: Entering directory `/usr/local/src/ruby-2.1.2/ext/socket' | |
linking shared-object socket.so | |
installing default socket libraries | |
make[2]: Leaving directory `/usr/local/src/ruby-2.1.2/ext/socket' | |
make[2]: Entering directory `/usr/local/src/ruby-2.1.2/ext/stringio' | |
installing default stringio libraries | |
make[2]: Leaving directory `/usr/local/src/ruby-2.1.2/ext/stringio' | |
make[2]: Entering directory `/usr/local/src/ruby-2.1.2/ext/strscan' | |
installing default strscan libraries |
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
#!/usr/bin/env ruby | |
require 'net/http' | |
require 'uri' | |
require 'json' | |
output = {} | |
s_json = JSON.parse(Net::HTTP.get_response(URI.parse('http://localhost:8500/v1/catalog/services')).body) | |
services = s_json.keys.reject{|k| k == 'consul'} | |
services.each do |srv| |