Closed frosas closed 1 year ago
HARNESS_BUILD_ID
or HARNESS_PIPELINE_ID
should be a good one I guess.
Sounds good to me. I also see in their public repo they're hardcoded so they should always be present https://github.com/harness/harness-core/search?q=HARNESS_BUILD_ID_VARIABLE
Let me know if you want me to submit a PR.
Sure. PR’s always welcome.
We can use HARNESS_BUILD_ID
. And make sure to update to README as well.
Details:
Environment variables
The relevant env vars I got by running a build:
Additional context
Harness uses Drone under the hood but, for some reason, it doesn't expose the
DRONE
env var ci-info is already capable to detect.We currently detect Harness CI by checking
DRONE_COMMIT
is truthy.