I like to do push -f of branch for merge request.
- can squash unnecessary 'fix bug' commit of following branch. 'fix bug' commit does not fix bug of original branch so it should be squashed.
- 'add feature xxx'
- 'fix bug of feature xxx'
| #!/bin/sh | |
| # sh i-want-this-bucket.sh bucket-name region-name | |
| while :; do | |
| date | |
| aws s3api create-bucket --bucket $1 --create-bucket-configuration LocationConstraint=$2 && break | |
| sleep 60 | |
| done |
導入:
Elastic Beanstalk で node.js のサーバ立てたときの様子。
80 番ポートへのアクセスはできる。
$ curl -I http://localhost:80/
HTTP/1.1 200 OK
Server: nginx/1.4.3
Date: Wed, 16 Apr 2014 02:19:18 GMT
Connection: keep-alive| var AWS = require("aws-sdk"); | |
| AWS.config.loadFromPath("./config.json"); | |
| var kinesis = new AWS.Kinesis(); | |
| kinesis.describeStream({ | |
| StreamName: "rch850-stream" | |
| }, function(err, data) { | |
| var startingSequenceNumber = data.StreamDescription.Shards[0].SequenceNumberRange.StartingSequenceNumber; |
| var AWS = require("aws-sdk"); | |
| AWS.config.loadFromPath("./config.json"); | |
| var kinesis = new AWS.Kinesis(); | |
| var params = { | |
| StreamName: "rch850-stream", | |
| PartitionKey: i + "", | |
| Data: new Buffer("oisiiryokucha" + i).toString("base64"), | |
| }; |
| #!/bin/sh -eu | |
| timeout=30 | |
| since=15 | |
| function usage() { | |
| cat >&2<<EOT | |
| Usage: $(basename $0) [-s since] [-t timeout] PATH... | |
| EOT |
| log_format postdata '$time_local $request $request_body'; | |
| location = /path { | |
| access_log /var/log/nginx/postdata.log postdata; | |
| proxy_pass http://localhost:8080; # <= set your port | |
| } |
| # Reset max_connections | |
| aws rds reset-db-parameter-group --db-parameter-group-name ENTERYOURS --parameters "ParameterName=max_connections,ApplyMethod=immediate" | |
| # Enable All Cross-Zone Load Balancing | |
| for lb in $(aws elb describe-load-balancers --query="LoadBalancerDescriptions[].LoadBalancerName" --output text); do | |
| echo $lb | |
| aws elb modify-load-balancer-attributes --load-balancer-name $lb --load-balancer-attributes '{"CrossZoneLoadBalancing":{"Enabled":true}}' | |
| done | |
| # Print my cf stack |
| #!/usr/bin/ruby | |
| require 'optparse' | |
| separator = "," | |
| source = false | |
| ARGV.clone.options do |opts| | |
| opts.banner = "Usage: #{$0} [options]" | |
| opts.on('-f', '--file=/path/to/file', String, 'Source file'){|v| | |
| source = v |