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
var client = require('webdriverjs').remote({ | |
desiredCapabilities: { | |
browserName: 'phantomejs' | |
}, | |
logLeve: 'silent' | |
}); | |
client.init(); | |
client |
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
-module(test_mnesia). | |
-import(lists, [foreach/2]). | |
-compile(export_all). | |
-include_lib("stdlib/include/qlc.hrl"). | |
-record(shop, {item, quantity, cost}). | |
-record(cost, {name, price}). | |
-record(design, {id, plan}). |
$ aws ec2 run-instance --image-id <ami-xxxxxxxx>
--key-name <keyName>
--security-group-ids <sg-xxxxxx>
--subnet-id <subnet-xxxxx>
--instance-type t1.micro
--associate-public-ip-address
$ brew install elasticsearch
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
var http = require('http'); | |
server = http.createServer(function (req, res) { | |
res.writeHead(200, {'Content-Type': 'text/plain'}); | |
res.end('Hello World\n'); | |
server.close(); | |
}); | |
server.listen(8080, 0, function () { | |
console.log('Server running at http://localhost:8080/'); | |
}); |
mongodbのデータディレクトリをアーカイブしてs3に保存.レプリカセットの場合はPRIMARYで実施.
% sudo tar -C /var/lib -cvz mongo | aws s3 cp - s3:///backup/mongodb-date '+%Y%m%d'
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
#!/bin/sh | |
# | |
# $ sudo yum install jq | |
# $ sudo pip install -U awscli | |
# # sh ./ebs-resize.sh -d /dev/xvdf -v ebs-volume-name | |
# | |
usage() { | |
echo "Usage: $0 -d device-name -v ebs-volume-name" 1>&2 | |
exit 1 |
OlderNewer