Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

## Changes #1

Closed
osamahassani05355881581 opened this issue Sep 10, 2022 · 0 comments
Closed

## Changes #1

osamahassani05355881581 opened this issue Sep 10, 2022 · 0 comments

Comments

@osamahassani05355881581
Copy link
Owner

Changes

If we have multiple metahook instances, let's not generate multiple temporary directories; instead just create one (and only dump the environment variables once). We also shard the vars file by the plugin configuration (calculating a hash using the standard cksum utility) so that you can have multiple metahook instances each with their own configuration (which is implicitly stored in the vars file).

I'm not sure why the vars file is created at all, as it seems it could be dynamically probed with [[ -v "BUILDKITE_PLUGIN_METAHOOK_${upperd}" ]] instead of using the grep on the vars file (since the variables should be live in the environment when the hook is actually executed), but I kept the current behavior.

Verification

This fixed an issue with multiple metahook instances in a pipeline of mine.

Originally posted by @staticfloat in improbable-eng/metahook-buildkite-plugin#12

Repository owner locked and limited conversation to collaborators Sep 10, 2022
@osamahassani05355881581 osamahassani05355881581 closed this as not planned Won't fix, can't repro, duplicate, stale Sep 10, 2022
Repository owner unlocked this conversation Sep 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant