petitviolet blog

    gcp (7 posts)

    icon
    Written by petitviolet

    Provisioning a custom domain on Cloud Run using Firebase Hosting

    2024-03-25GCPFirebase
    Firebase Hosting now can be used for provisioning a domain on Cloud Run instead of running a load balancer
    It used to be that using a load balancer is the most common way to provision a custom domain on Cloud Run. However, it's a bit complicated and costly because it requires a load balancer. In order to have lower running cost, using load balancer should not be the best option. For provisioning custom

    Terraform to provision GCP CDN for GCS backend

    2023-02-20TerraformGCP
    Provision CDN on GCS in GCP using Terraform
    Google Cloud offers CDN(content delivery/distributed network) that can be backed by Cloud Storage, a.k.a GCS. Terraform supports provisioning CDN in GCP as always. As well as the previous post, in Terraform, variables should be declared in variables.tf but use locals here instead for simplicity

    GCP IAP protected Cloud Run Application by Terraform

    2023-01-18GCPCloudRunTerraform
    Terraform to build a Cloud Run Application protected by GCP Identity-Aware Proxy
    Google Cloud(GCP) has Identity-Aware Proxy that uses ID and contexts to protect applications and VMs from unexpected access. https://cloud.google.com/iap Thanks to IAP, it's a way easy to protect an application running on Cloud Run by requiring Google login within the organization, for example.

    Terraform to manage GCP Service Accounts

    2022-06-30TerraformGCP
    Terraform provides a few methods for managing Service Accounts in GCP. This post attempts to describe how to create Service Accounts in a good manner.
    The Google provider of Terraform has some mechanisms to manage Service Accounts in GCP as followings. - [google_service_account_iam](https://registry.terraform.io/providers/hashicorp/google/latest/docs/resources/google_service_account_iam) - google_service_account_iam_policy - google_servi

    How to deploy a Next.js application running on Cloud Run via GitHub Actions

    2022-01-25GCPNext.jsCloud RunGitHub Actions
    Explain how to deploy a blog powered by Next.js to GCP Cloud Run through GitHub Actions
    As I posted before, this blog is running on GCP Cloud Run and also is built with Next.js. https://blog.petitviolet.net/post/2021-12-28/running-a-blog-powered-by-next.js-on-cloud-run Previously, before migrating to Next.js from Gatsby, this blog used to get deployed automatically via GitHub Action

    Running a blog powered by Next.js on Cloud Run

    2021-12-28Next.jsGCPCloud Run
    Build a blog with Next.js and run it on GCP Cloud Run which is a managed platform for enabling users to run containers very easily
    This blog had been built with [Gatsby](https://nextjs.org), but I decided to migrate to [Next.js](https://nextjs.org) just for learning it. This post is going to describe what the arcitecture is and how to deploy this blog to [GCP Cloud Run](https://cloud.google.com/run) which is a serverless platf

    GAE SE for Java8でStackdriver Loggingのログがずれる問題

    2017-12-17QiitaJavaScalaGAEgcpStackdriverLogging
    GoogleAppEngineStandardEnvironmentforJav
    Google AppEngine Standard Environment for Java8 に乗せたアプリケーションで非同期処理しつつログ出力すると、 ログがリクエストに正しく紐付かずに別のリクエストのログとして出力されてしまう、という細かすぎて伝わらない問題と戦った話です。 なお言語は Scala で、[Skinny Micro](http://skinny-framework.org/documentation/micro.html)を使用。 まとめ まず結論。 GAE では独自のスレッドではなくThreadManager.createThreadForCurrentR