Skip to content

Instantly share code, notes, and snippets.

View masahide's full-sized avatar

YAMASAKI Masahide masahide

View GitHub Profile
@masahide
masahide / config
Created February 23, 2014 07:42
go でmapや配列等を pretty print (var_dumpみたいな何か)と yaml の読み込み ref: http://qiita.com/yamasaki-masahide/items/327ad9c423de1e35215f
mail_from: masahide.y@gmail.com
to: [masahide.y@gmail.com]
var:
c: 2
d: [3, 4]
@masahide
masahide / config
Created February 25, 2014 04:44
go で yaml 等を「map[interface{}]interface{}」型で読み込んだ際の動的型の参照方法 ref: http://qiita.com/yamasaki-masahide/items/d6e406c4c11d5870a1c6
mail_from: hoge@fuga.com
to: [hoge@fuga.com]
var:
c: 2
d: [3, 4]
@masahide
masahide / docker
Created April 10, 2014 11:21
EC2上にdrone.ioのオープンソース版を載せて「Rebuild」ボタンを追加するパッチを当てる ref: http://qiita.com/yamasaki-masahide/items/686e20b614c838201636
ubuntu@drone:~$ cat /etc/default/docker
# Docker Upstart and SysVinit configuration file
# Customize location of Docker binary (especially for development testing).
#DOCKER="/usr/local/bin/docker"
# Use DOCKER_OPTS to modify the daemon startup options.
#DOCKER_OPTS="-dns 8.8.8.8 -dns 8.8.4.4"
DOCKER_OPTS="-H tcp://0.0.0.0:4243 -H unix:///var/run/docker.sock"
@masahide
masahide / file0.txt
Created April 13, 2014 02:14
Go言語 drone.ioで自動クロスコンパイル CI環境 #golang ref: http://qiita.com/yamasaki-masahide/items/b4348388267a703b4de5
pkg/os/error_unix.go:11: isExist redeclared in this block
previous declaration at pkg/os/error_posix.go:11
@masahide
masahide / file0.txt
Created April 22, 2014 01:16
VMware player NATで起動したゲストOSにssh接続する ref: http://qiita.com/yamasaki-masahide/items/ccb62e98dff99c2a22a1
host VMnet8 {
# ubuntu
hardware ethernet 00:0c:11:bb:cc:dd;
fixed-address 192.168.21.127;
}
#End
[BatchWriteItem] – 1 回のトランザクションとしてではなく、1回のリクエストで、複数のテーブル間で複数の項目を挿入、置換、削除します。Put または Delete で最大 25 項目のバッチをサポートし、合計リクエストサイズは最大 1 MB です。
@masahide
masahide / file0.txt
Last active August 29, 2015 14:00
S3へ最高のパフォーマンスでログを保存する ref: http://qiita.com/yamasaki-masahide/items/7c44ea17d9901601f38c
examplebucket/2013-26-05-15-00-00/host01/apache/access_log
examplebucket/2013-26-05-15-00-00/host02/apache/access_log
examplebucket/2013-26-05-15-00-00/host03/apache/access_log
examplebucket/2013-26-05-15-00-00/host04/apache/access_log
@masahide
masahide / file0.txt
Last active August 29, 2015 14:02
Cybozu ガルーン API を使ってみる ref: http://qiita.com/yamasaki-masahide/items/fff1c84e65043ac4caf7
Garoon on cybozu.com: https://(サブドメイン名).cybozu.com/g/index.csp?WSDL
パッケージ版 Windows 環境:http://(インストールしたサーバーの IP アドレスまたはホスト名)/scripts/(インストール識別子)/grn.exe?WSDL
パッケージ版 Linux 環境:http://(インストールしたサーバーの IP アドレスまたはホスト名)/cgi-bin/(インストール識別子)/grn.cgi?WSDL
@masahide
masahide / file0.go
Last active June 25, 2018 13:23
Cybozu ガルーン API を golang で叩いてみる ref: http://qiita.com/yamasaki-masahide/items/03dfa6cd70ff20607b58
const SOAPRequest = `<?xml version="1.0" encoding="UTF-8"?>
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://www.w3.org/2003/05/soap-envelope"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:base_services="http://wsdl.cybozu.co.jp/base/2008">
<SOAP-ENV:Header>
<Action SOAP-ENV:mustUnderstand="1" xmlns="http://schemas.xmlsoap.org/ws/2003/03/addressing">{{.Action}}</Action>
<Security xmlns:wsu="http://schemas.xmlsoap.org/ws/2002/07/utility"
SOAP-ENV:mustUnderstand="1"
@masahide
masahide / file0.xml
Created June 19, 2014 00:21
Cybozu ガルーン API のレスポンスのXMLを golang でパースする ref: http://qiita.com/yamasaki-masahide/items/f20a2ca4700e00777303
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope
xmlns:soap="http://www.w3.org/2003/05/soap-envelope"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
xmlns:schedule="http://wsdl.cybozu.co.jp/schedule/2008">
<soap:Header>・・・・・</soap:Header>
<soap:Body>
<schedule:ScheduleGetEventsResponse>
<returns>