Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions src/providers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,8 @@ export type ProviderName =
| "cirrus"
| "cloudflare_pages"
| "cloudflare_workers"
| "google_cloudrun"
| "google_cloudrun_job"
| "codebuild"
| "codefresh"
| "drone"
Expand Down Expand Up @@ -72,6 +74,8 @@ const providers: InternalProvider[] = [
["CIRRUS", "CIRRUS_CI"],
["CLOUDFLARE_PAGES", "CF_PAGES", { ci: true }],
["CLOUDFLARE_WORKERS", "WORKERS_CI", { ci: true }],
["GOOGLE_CLOUDRUN", "K_SERVICE", { ci: true }],
Copy link
Member

@pi0 pi0 Jun 25, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is K_SERVICE also for CI? (why we could need to make a distinction in this case between job and non job variant)

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was very confused the by the ci: true flag when editing the file. Neither Cloud Run or Cloud Run jobs are Continuous Integration tools. But from my understanding neither it is FIREBASE_APP_HOSTING but it has the flag true.

To the question, do we need to distinguish regular and jobs. There is a fine line there, they both run in Cloud Run. The purpose is different (one for requests, one for jobs). The environment variables are not exactly the same, neither the run time behaviour (Cloud Run Jobs runs "forever" the process, regular Cloud Run does not).

Do we want to expose it in this package, that's a good question. I didn't need it, and implemented it for "completion" but now I am not so sure. 🤔

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But from my understanding neither it is FIREBASE_APP_HOSTING but it has the flag true.

This variable is only set in their deployment CI/CD (not deployment runtime)

["GOOGLE_CLOUDRUN_JOB", "CLOUD_RUN_JOB", { ci: true }],
["CODEBUILD", "CODEBUILD_BUILD_ARN"],
["CODEFRESH", "CF_BUILD_ID"],
["DRONE"],
Expand Down