Entries from 2018-01-01 to 1 month
If you want to make sure ec2 instance information from inner itself, you should check this post. (Describes about in the case of EC2-AmazonLinux which has already installed `aws` command.)For instance this is an alias named `me` that outpu…
ELB (ALB) + EC2*2(apache)にvirtual hostでマッピングしたサービスにBasic認証をかけたい。 ただしELBはstatus=200のチェックのままで、この辺はいじりたくないなぁって時の話です。上記のようなAWS上の設定やアプリの設定を極力変えずにBasic認証をかける…
I had misunderstanding for "permissions" in appspec.yml of AWS CodeDeploy. Say around that we have an app which directory structure is like below. CodeDeployのappspec.ymlで使うpermissionセクションについて誤解してた。。 例えば以下のような構…
We have a web service with AWS, located in like below environment. (This time in case of using AmazonLinux) WebServer: - Production: - ALB * 1 - EC2 * 2 - Dev: - EC2 * 1 DB: - Production: Aurora * 1 - Dev: Aurora * 1 Our source code is m…
sliceは可変長の配列を扱うデータ型で、ベースとなる配列のポインタと要素数、および容量(capacity)を持っている。sliceリテラルやmakeはベースとなる配列を作成した上でそのsliceを返している。 sliceは参照型なので、sliceの要素を変更すればベースとなる…
Goでjsonを扱う場合、json文字列をbyte配列にしたものをencoding/jsonパッケージのunmarshalに渡し、あらかじめ定義しておいた構造体に入れるといったのが定番ですが、その際に構造体のフィールド名を先頭を大文字にしていないとマッピングできないというこ…