-
Notifications
You must be signed in to change notification settings - Fork 72
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
Add CI job to enable/disable GH PR merging #1508
Conversation
docker/scripts/github.ts
Outdated
const binKey = sodium.from_base64(repositoryPublicKey, sodium.base64_variants.ORIGINAL); | ||
const binSecret = sodium.from_string(`${flag}`); | ||
|
||
//Encrypt the secret using LibSodium |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit:
@@ -56,6 +56,9 @@ | |||
"docker:scripts:docker:build:local": "yarn docker:scripts:docker:build --npm-registry local --npm-tag local --docker-tag local", | |||
"docker:scripts:docker:publish": "docker run --rm -v /var/run/docker.sock:/var/run/docker.sock -e DOCKERHUB_USERNAME -e DOCKERHUB_TOKEN api3/airnode-packaging:latest docker publish", | |||
"docker:scripts:docker:publish:latest": "yarn docker:scripts:docker:publish", | |||
"docker:scripts:github": "docker run --rm -v /var/run/docker.sock:/var/run/docker.sock -e GITHUB_TOKEN api3/airnode-packaging:latest github", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to set the GH token when running this command. It might be nice to mention this somewhere. Maybe root README?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There's a README in the docker
directory that I'm forgetting to update. I'll do that.
a52476a
to
26d711b
Compare
2ddc740
to
ecb6557
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍 LGTM
80a3781
to
fc959af
Compare
ecb6557
to
632f93d
Compare
During the release flow, there's a time window when we need to "freeze" merging in order to release only what was tested during the testing of snapshot packages. I added a CI job whose sole purpose is just to check the GitHub secret and succeed or fail based on its value. I also added a command to the packaging container allowing us to set this secret to either
true
orfalse
, effectively controlling whether the CI check will be successful and therefore whether the merge will be allowed.