Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
141 commits
Select commit Hold shift + click to select a range
b4d80e6
Add profile to s3credentials
Eden-D-Zhang Feb 13, 2025
1cfd858
Add support for aws profile in s3 utils
Eden-D-Zhang Feb 13, 2025
10d3cfb
typo
Eden-D-Zhang Feb 13, 2025
a325628
Remove trailing whitespace
Eden-D-Zhang Feb 24, 2025
d95333c
Add `~/.aws` directory to clp_config
Eden-D-Zhang Feb 24, 2025
46c2269
Add aws_config_dir mount to scheduler and worker containers
Eden-D-Zhang Feb 26, 2025
5293897
Add function to retrieve credentials from session started from profile
Eden-D-Zhang Mar 1, 2025
c1e7ddc
Add session token to S3Credentials
Eden-D-Zhang Mar 1, 2025
a3230a2
Add temporary credential support to extract_stream
Eden-D-Zhang Mar 1, 2025
88d6f03
Add temporary credentials to fs_search_task, check for no credentials
Eden-D-Zhang Mar 1, 2025
4499dc5
Fix typo
Eden-D-Zhang Mar 1, 2025
dc272a7
Lint fixes
Eden-D-Zhang Mar 1, 2025
11d0f7c
Add support to compress from S3
Eden-D-Zhang Mar 4, 2025
939eee4
Lint fixes
Eden-D-Zhang Mar 4, 2025
1e3a3cb
Add session token to webui env vars **TEMPORARY**
Eden-D-Zhang Mar 4, 2025
e07c0fc
Mount aws config only if S3 is enabled
Eden-D-Zhang Mar 5, 2025
e97a78c
Lint
Eden-D-Zhang Mar 5, 2025
add24d2
Add support for long-term profile
Eden-D-Zhang Mar 5, 2025
1a6142c
Implement review suggestions
Eden-D-Zhang Mar 6, 2025
422784c
Fix compression command
Eden-D-Zhang Mar 10, 2025
3856d08
Add profile to log viewer S3Manager
Eden-D-Zhang Mar 10, 2025
cb070ad
Remove unnecessary log
Eden-D-Zhang Mar 10, 2025
67a7901
Merge branch 'main' into s3-auth-support
Eden-D-Zhang Mar 10, 2025
12ae9be
Merge branch 'y-scope:main' into s3-auth-support
Eden-D-Zhang Mar 11, 2025
6bd382b
Apply suggestions from code review
Eden-D-Zhang Mar 12, 2025
fc9a902
Remove unused imports, add validator to s3inputconfig
Eden-D-Zhang Mar 12, 2025
82e2f81
Mount aws_config_dir only if profile is specified
Eden-D-Zhang Mar 12, 2025
cb173dc
Lint fixes
Eden-D-Zhang Mar 12, 2025
d520391
Merge branch 'y-scope:main' into s3-auth-support
Eden-D-Zhang Mar 12, 2025
9822dba
Merge branch 's3-auth-support' of https://github.com/Eden-D-Zhang/clp…
Eden-D-Zhang Mar 12, 2025
d508633
Fix duplicate mount
Eden-D-Zhang Mar 12, 2025
77dadf0
Fix log-viewer using credentials
Eden-D-Zhang Mar 13, 2025
df4723c
Move S3 client generation to helper function
Eden-D-Zhang Mar 13, 2025
bfdf94b
Lint
Eden-D-Zhang Mar 13, 2025
1ac253d
Fix
Eden-D-Zhang Mar 13, 2025
49852df
Merge branch 'y-scope:main' into s3-auth-support
Eden-D-Zhang Mar 16, 2025
784ebb5
Update get_session_credentials to work without profile
Eden-D-Zhang Mar 16, 2025
32e72ee
Merge branch 'y-scope:main' into s3-auth-support
Eden-D-Zhang Mar 20, 2025
6315083
Merge branch 's3-auth-support' of https://github.com/Eden-D-Zhang/clp…
Eden-D-Zhang Mar 20, 2025
8d712b7
Change S3Storage class to S3OutputStorage
Eden-D-Zhang Mar 20, 2025
88b0e28
Make S3InputStorage class
Eden-D-Zhang Mar 20, 2025
64caa6f
Change `input_logs_directory` to `logs_input`
Eden-D-Zhang Mar 20, 2025
d043d94
Change mount for input_logs_dir to only mount when type FS
Eden-D-Zhang Mar 21, 2025
f5c54b8
Whitespace
Eden-D-Zhang Mar 24, 2025
f0d45b2
Shorten class names
Eden-D-Zhang Mar 24, 2025
c9f11b0
Refactor classes
Eden-D-Zhang Mar 24, 2025
38276d3
Change InputS3Storage to S3Storage
Eden-D-Zhang Mar 24, 2025
aa16f17
Change S3 compression to use logs_input s3_config instead of URL
Eden-D-Zhang Mar 25, 2025
3395d78
Update error message
Eden-D-Zhang Mar 26, 2025
685fd14
Merge branch 'y-scope:main' into log-input-storage
Eden-D-Zhang Mar 26, 2025
042a392
Remove parse_s3_url function
Eden-D-Zhang Mar 26, 2025
61e974c
Remove unused functions
Eden-D-Zhang Mar 26, 2025
21869df
Remove unused imports
Eden-D-Zhang Mar 26, 2025
8b936d5
Update docs
Eden-D-Zhang Mar 26, 2025
75426c2
Fix missing change in docs
Eden-D-Zhang Mar 26, 2025
5aef10c
Add link to docs
Eden-D-Zhang Mar 26, 2025
4cc3337
Remove `fs` from other docs
Eden-D-Zhang Mar 26, 2025
bc7b7f7
Update components/clp-package-utils/clp_package_utils/scripts/native/…
Eden-D-Zhang Mar 26, 2025
f932ba1
Merge branch 'main' into s3-auth-support
Eden-D-Zhang Mar 31, 2025
06dc762
Fix S3Manager null profile case
Eden-D-Zhang Apr 1, 2025
cfbec47
`Merge remote-tracking branch 'origin/log-input-storage' into s3-auth…
Eden-D-Zhang Apr 2, 2025
3a768d0
Make AwsAuthentication class
Eden-D-Zhang Apr 2, 2025
ebc3070
Add AwsAuthentication to S3Config and S3InputConfig, improve validati…
Eden-D-Zhang Apr 2, 2025
556a2d2
Replace `config` and `credentials` references with `aws_authenticatio…
Eden-D-Zhang Apr 3, 2025
1280abd
Remove unused imports
Eden-D-Zhang Apr 3, 2025
4be1842
Add aws environmental variables to log viewer if `type` "env_vars" is…
Eden-D-Zhang Apr 3, 2025
4c6c452
Change _generate_s3_client to _create_s3_client
Eden-D-Zhang Apr 5, 2025
454ca32
Change S3InputConfig to inherit from S3Config
Eden-D-Zhang Apr 7, 2025
7f6a108
Remove `**os.environ` from get_credential_env_vars, callers combine i…
Eden-D-Zhang Apr 7, 2025
0274477
Add .aws mount for `logs_input` type "profile"
Eden-D-Zhang Apr 7, 2025
142e047
Fix env_vars variable name
Eden-D-Zhang Apr 7, 2025
3789f1f
Lint
Eden-D-Zhang Apr 9, 2025
6ac7b09
Make function to get docker container command line options for aws au…
Eden-D-Zhang Apr 9, 2025
5763206
Add functions to append mounts and env vars to container start commands
Eden-D-Zhang Apr 9, 2025
e62b236
Change append_docker_mounts to append only if mount exists
Eden-D-Zhang Apr 9, 2025
6ab6420
Integrate new append functions into starting containers
Eden-D-Zhang Apr 9, 2025
8655fe2
Correct get_container_authentication docstring
Eden-D-Zhang Apr 10, 2025
5471627
Add empty string check for append_docker_env_vars
Eden-D-Zhang Apr 10, 2025
d78ab8c
Fixes
Eden-D-Zhang Apr 10, 2025
f088daa
Change empty string check to use `!=`
Eden-D-Zhang Apr 10, 2025
c07474f
Fixes again
Eden-D-Zhang Apr 10, 2025
8162162
Add aws authentication mounts and env vars to containers
Eden-D-Zhang Apr 10, 2025
25c7be4
Fix returning None instead of empty dict
Eden-D-Zhang Apr 10, 2025
19ef542
Add comment
Eden-D-Zhang Apr 10, 2025
42c75d6
Improve S3Manager constructor
Eden-D-Zhang Apr 10, 2025
12eb344
Remove unused mount
Eden-D-Zhang Apr 10, 2025
bc4ad04
Merge branch 'main' into s3-auth-support
Eden-D-Zhang Apr 13, 2025
cd20485
Lint
Eden-D-Zhang Apr 14, 2025
5ad0a5c
Enforce yoda condition format and remove unused function argument
Eden-D-Zhang Apr 14, 2025
32bca27
Fixes
Eden-D-Zhang Apr 14, 2025
51dcb99
Add env var credential for tasks on ec2
Eden-D-Zhang Apr 15, 2025
e06e425
Merge branch 'main' into s3-auth-support
Eden-D-Zhang Apr 15, 2025
b04e827
Rename `get_session_credentials` function to show that it is internal
Eden-D-Zhang Apr 15, 2025
968c167
Update components/clp-package-utils/clp_package_utils/general.py
Eden-D-Zhang Apr 15, 2025
1d0573e
Replace AwsAuthentication type with AwsAuthType enum class
Eden-D-Zhang Apr 17, 2025
c5aa9ec
Implement review suggestions
Eden-D-Zhang Apr 17, 2025
60155ef
Replace get_container_authentication type parameter with ContainerTyp…
Eden-D-Zhang Apr 17, 2025
a2eb649
Change env to env_vars in AwsAuthType
Eden-D-Zhang Apr 17, 2025
e1d4113
Fix AwsAuthType YAML representation
Eden-D-Zhang Apr 17, 2025
cece230
Combine functions to append docker options
Eden-D-Zhang Apr 17, 2025
1bca3f8
Add validation check for aws_config_directory
Eden-D-Zhang Apr 17, 2025
bf5c66c
Clean up get_container_authentication function
Eden-D-Zhang Apr 17, 2025
98e529b
Lint
Eden-D-Zhang Apr 17, 2025
eab25a0
Change get_container_authentication method name, type input, move cal…
Eden-D-Zhang Apr 17, 2025
2f1b0ee
Update clp-config.yml template
Eden-D-Zhang Apr 17, 2025
d87095b
Remove import
Eden-D-Zhang Apr 17, 2025
90b26d6
Rename necessary_env_vars to env_vars when there are no additional en…
Eden-D-Zhang Apr 17, 2025
393e19e
Update validation for AwsAuthentication
Eden-D-Zhang Apr 17, 2025
152d039
Lint
Eden-D-Zhang Apr 17, 2025
ac4d7c0
Update docs
Eden-D-Zhang Apr 21, 2025
3aa4363
Apply suggestions from code review
Eden-D-Zhang Apr 21, 2025
beca05f
Refactor credentials hanling for get_credential_env_vars
Eden-D-Zhang Apr 21, 2025
45d76ac
Implement review suggestions
Eden-D-Zhang Apr 21, 2025
cc23450
Make config optional for boto3 s3 client generation
Eden-D-Zhang Apr 21, 2025
8b24a80
Apply review suggestions
Eden-D-Zhang Apr 21, 2025
4a65d51
Apply coderabbit suggestions
Eden-D-Zhang Apr 21, 2025
a18e71a
Update validation for aws_config_dir
Eden-D-Zhang Apr 21, 2025
3567dc7
Merge branch 'y-scope:main' into s3-auth-support
Eden-D-Zhang Apr 21, 2025
d0f7b60
Lint
Eden-D-Zhang Apr 21, 2025
64732b4
Merge branch 'main' into s3-auth-support
Eden-D-Zhang Apr 22, 2025
414f1ce
Unset S3 profile for log viewer if not in use
Eden-D-Zhang Apr 23, 2025
ba0d164
Update components/clp-package-utils/clp_package_utils/scripts/start_c…
Eden-D-Zhang Apr 23, 2025
bb7576d
Update components/log-viewer-webui/server/src/plugins/S3Manager.ts
Eden-D-Zhang Apr 23, 2025
bad6337
Apply review suggestion
Eden-D-Zhang Apr 23, 2025
bf7565a
Add section about aws config directory to docs.
Eden-D-Zhang Apr 23, 2025
cc860bd
Change text formatting
Eden-D-Zhang Apr 23, 2025
f032cb6
Apply suggestions from code review
Eden-D-Zhang Apr 24, 2025
a85e16c
Update docs with review suggestions
Eden-D-Zhang Apr 24, 2025
98221f4
Update docs/src/user-guide/guides-using-object-storage/index.md
Eden-D-Zhang Apr 24, 2025
5168676
Refactor docs.
kirkrodrigues Apr 24, 2025
9b03123
Address rabbit's review.
kirkrodrigues Apr 24, 2025
6c36fdb
Change None to null
Eden-D-Zhang Apr 25, 2025
0c5ab8b
Address Eden's review.
kirkrodrigues Apr 25, 2025
c3d51f0
Minor refactoring.
kirkrodrigues Apr 25, 2025
3c7492c
Apply suggestions from code review
Eden-D-Zhang Apr 25, 2025
2a7cda6
Apply review suggestions
Eden-D-Zhang Apr 25, 2025
28bd145
Update docs/src/user-guide/guides-using-object-storage/index.md
kirkrodrigues Apr 25, 2025
28d1df4
Edit Haiqi's suggestion.
kirkrodrigues Apr 25, 2025
92c6ab6
Replace AWS credental names with constants.
Eden-D-Zhang Apr 25, 2025
b56ac35
Add session token constant and use constants in error messages.
Eden-D-Zhang Apr 25, 2025
c9f2c07
Fix single string constant formatting
Eden-D-Zhang Apr 25, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions components/clp-package-utils/clp_package_utils/general.py
Original file line number Diff line number Diff line change
Expand Up @@ -88,6 +88,7 @@ def __init__(self, clp_home: pathlib.Path, docker_clp_home: pathlib.Path):
self.logs_dir: typing.Optional[DockerMount] = None
self.archives_output_dir: typing.Optional[DockerMount] = None
self.stream_output_dir: typing.Optional[DockerMount] = None
self.aws_config_dir: typing.Optional[DockerMount] = None


def get_clp_home():
Expand Down Expand Up @@ -268,6 +269,14 @@ def generate_container_config(
container_clp_config.stream_output.get_directory(),
)

# Only create the mount if the directory exists
if clp_config.aws_config_directory is not None:
container_clp_config.aws_config_directory = pathlib.Path("/") / ".aws"
docker_mounts.aws_config_dir = DockerMount(
DockerMountType.BIND,
clp_config.aws_config_directory,
container_clp_config.aws_config_directory,
)
return container_clp_config, docker_mounts


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import uuid
from typing import List

from clp_py_utils.clp_config import CLPConfig, StorageEngine
from clp_py_utils.clp_config import StorageEngine
from job_orchestration.scheduler.job_config import InputType

from clp_package_utils.general import (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ def _generate_clp_io_config(
region_code=s3_config.region_code,
bucket=s3_config.bucket,
key_prefix=s3_config.key_prefix + logs_to_compress[0],
credentials=s3_config.credentials,
aws_authentication=s3_config.aws_authentication,
timestamp_key=parsed_args.timestamp_key,
)
else:
Expand Down
Loading