Interfaces for IAM in S3 client

This commit is contained in:
Yaroslava Lukoyanova 2023-11-23 15:53:03 +03:00 committed by ylukoyan
parent 863e74f161
commit 65ec50391e
4 changed files with 1039 additions and 17 deletions

View file

@ -41,7 +41,7 @@ def _run_with_passwd(cmd: str) -> str:
return cmd.decode()
def _configure_aws_cli(cmd: str, key_id: str, access_key: str, out_format: str = "json") -> str:
def _configure_aws_cli(cmd: str, key_id: str, access_key: str, region: str, out_format: str = "json") -> str:
child = pexpect.spawn(cmd)
child.delaybeforesend = 1
@ -52,7 +52,7 @@ def _configure_aws_cli(cmd: str, key_id: str, access_key: str, out_format: str =
child.sendline(access_key)
child.expect("Default region name.*")
child.sendline("")
child.sendline("region")
child.expect("Default output format.*")
child.sendline(out_format)