Google Container Registryを使う場合にはlocationに注意
Google Container Registryを使う時には
asia-northeast1で使うならasia.gcr.ioというように
pullする場所に近いlocationを選んでおいた方が余計なコストがかからないですよ、というお話です。
ドキュメントでは基本的にgcr.ioが使われているからといって、そのまま使っていると思ったよりも費用がかかってしまうことがあるのでご注意ください(何も考えずに使っていたら余計なコストがかかって悲しかった…)。
特にSKU別でみた時に、意図せず
「GCP Storage egress between NA and APAC」
で大きめの費用がかかっているなら見直してみる価値があると思います。
話としては以上です。実際どう料金が算出されるのかも書いておくのでご興味があれば。
Google Container Registryの料金
- Pricing | Container Registry | Google Cloudによれば、Container RegistryのNetwork egress料金はCloud Storage準拠のようです。
- Cloud Storageの料金はPricing | Cloud Storage | Google Cloudとのことです。
以下 gcr.io → asia-northeast1, asia.gcr.io → asia-northeast1 で比較をしてみます。
gcr.io → asia-northeast1 の場合
gcr.ioはUSにあります。
US→asia-northeast1の料金はテーブルの
Data moves between different continents and neither is Australia. にあたり、
See the "Egress to Worldwide destinations" column of the General network usage table.
とのことなので見てみると、Egress to Asia Destinationsなので $0.1/GB程度 です。
asia.gcr.io → asia-northeast1 の場合
asia.gcr.io は名前の通りAsiaにあります。
ASIA→asia-northeast1の料金はテーブルの
Data moves from a Cloud Storage bucket located in a multi-region to a different Google Cloud service located in a region, and both locations are on the same continent.
にあたり無料です。
Discussion