-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
[v9] Adds optional deployment key for CI (#10506) #12590
Merged
Merged
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
There are private copies of the teleport repo that require the use of deployment keys to perform operations on the code repository (e.g. `git fetch --unshallow`). This patch adds the ability for a GCB build trigger to optionally pass in the location of a secret deployment key, which will be fetched and used if supplied. If no such deployment key is supplied (i.e. in the public teleport repo), the build will have access to neither the location of the deployment key, nor the key itself, and thus cannot leak it during CI. This patch also pulls the unshallow operation into the main build script (as opposed to being a separate build step) so it can use the deployment key to grant access to the remote repo. Most of the new interaction with the repository is via shelling out to the command-line git installed on the buildbox. My original intention was to use go-git to manage the unshallow directly from code, but this was not supported by the library.
r0mant
approved these changes
May 11, 2022
github-actions
bot
requested review from
espadolini,
greedy52,
r0mant,
russjones and
zmb3
May 11, 2022 23:14
jakule
approved these changes
May 12, 2022
r0mant
added a commit
that referenced
this pull request
May 12, 2022
tcsc
added a commit
that referenced
this pull request
May 13, 2022
tcsc
added a commit
that referenced
this pull request
May 19, 2022
tcsc
added a commit
that referenced
this pull request
May 23, 2022
Closed
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There are private copies of the teleport repo that require the use of
deployment keys to perform operations on the code repository (e.g.
git fetch --unshallow
).This patch adds the ability for a GCB build trigger to optionally pass
in the location of a secret deployment key, which will be fetched and
used if supplied.
If no such deployment key is supplied (i.e. in the public teleport repo),
the build will have access to neither the location of the deployment key,
nor the key itself, and thus cannot leak it during CI.
This patch also pulls the unshallow operation into the main build script (as
opposed to being a separate build step) so it can use the deployment key
to grant access to the remote repo.
Most of the new interaction with the repository is via shelling out to the
command-line git installed on the buildbox. My original intention was to
use go-git to manage the unshallow directly from code, but this was not
supported by the library.