Remix.run Logo
▲ CharlieDigital 3 hours ago

Cloud Run says "Hi"

Edit: even better for .NET and Java as Cloud Run supports startup CPU boost[0] to improve initial cold start JIT performance.

What this looks like deploying a .NET web API to Cloud Run:

    # Auth first: gcloud auth configure-docker us-central1-docker.pkg.dev
    # Package and push using .NET tools (built in)
    dotnet publish --os linux --arch x64 /t:PublishContainer \
      -p ContainerRegistry=us-central1-docker.pkg.dev \
      -p ContainerRepository=ORG/REG/IMG \
      -c Release

    # Deploy web API to Cloud Run
    gcloud run deploy SVC \
      --image=us-central1-docker.pkg.dev/ORG/REG/IMG:latest \
      --project=PROJ \
      --region=us-central1 \
      --cpu-boost \
      --max-instances=2 \
      --min-instances=0

    # Get back a URL to the ingress
I run a bunch of workloads "for free" because most apps are going to fall into the monthly credit pool (180k vCPU seconds; 50h @ 1 vCPU) if it scales to 0.

[0] https://cloud.google.com/blog/products/serverless/announcing...

▲jack_sunsetless 3 hours ago | parent [-]

[flagged]