forked from ClickHouse/ClickHouse
-
Notifications
You must be signed in to change notification settings - Fork 9
24.8 Use credentials from secrets #693
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
Merged
Enmk
merged 18 commits into
customizations/24.8.14
from
24.8/cicd-fix/get_docker_from_secrets
Mar 26, 2025
Merged
Changes from all commits
Commits
Show all changes
18 commits
Select commit
Hold shift + click to select a range
d174862
get docker credentials from secrets
MyroTk 581666d
add docker password to env
MyroTk a31e6b4
add secrets to env and prevent aws leaks
MyroTk a6d14f9
use temp test bucket
MyroTk 0377def
fix syntax issue
MyroTk af1aeef
avoid using env_helper module in packager
MyroTk a1955ae
fix dict issue
MyroTk 93a3913
fix dict
MyroTk f06682c
update envs in build script
MyroTk 0f5c6c5
aws config file fix
MyroTk 288a32f
update aws config path inside docker
MyroTk eff4415
aws credentials path inside docker
MyroTk 9ac681f
move aws credentials to the correct user inside container
MyroTk abf28f5
change aws credentials directory. again.
MyroTk 95644cb
switch back to altinitybuild0artifacts bucket
MyroTk 530a662
Update secrets definition in workflows and temp path in packager
MyroTk 781e811
remved unused module_dir
Enmk 926c396
fix regression aws secrets and robot token function
MyroTk File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -10,6 +10,7 @@ | |
| from github.GithubException import BadCredentialsException | ||
| from github.NamedUser import NamedUser | ||
|
|
||
| from env_helper import ROBOT_TOKEN | ||
|
|
||
| @dataclass | ||
| class Token: | ||
|
|
@@ -56,20 +57,11 @@ def get_parameters_from_ssm( | |
|
|
||
| return results | ||
|
|
||
|
|
||
| ROBOT_TOKEN = None # type: Optional[Token] | ||
|
|
||
| # NOTE(Arthur Passos): Original CI code uses the "_original" version of this method. Each robot token is rate limited | ||
| # and the original implementation selects the "best one". To make it simpler and iterate faster, | ||
| # we are using only one robot and keeping the method signature. In the future we might reconsider | ||
| # having multiple robot tokens | ||
| def get_best_robot_token(token_prefix_env_name="github_robot_token"): | ||
| # Re-use already fetched token (same as in get_best_robot_token_original) | ||
| # except here we assume it is always a string (since we use only one token and don't do token rotation) | ||
| global ROBOT_TOKEN | ||
| if ROBOT_TOKEN is not None: | ||
| return ROBOT_TOKEN | ||
| ROBOT_TOKEN = get_parameter_from_ssm(token_prefix_env_name) | ||
| def get_best_robot_token(): | ||
| return ROBOT_TOKEN | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. It looks like ROBOT_TOKEN = None # type: Optional[Token] |
||
|
|
||
| def get_best_robot_token_original(tokens_path: str = "/github-tokens") -> str: | ||
|
|
||
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.
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.
It looks like we need to add those to the section above for this worklow to work properly on
workflow_call