Batch file to download files via CLI from S3 bucket to a drive passing keys

2021-09-15T07:34:38.49+00:00

Hi All

I'm a newbie to AWS, I need to automate a file download from S3 bucket to a network drive, using AWS CLI command which requires creating a batch file and pass the access key/secret key & the below command to download the files.

Can you advise me on how to create this batch file to pass the keys?

aws s3 cp --profile stage s3://stage-1/dbexport/ ~/LOCAL_DESTINATION/

Also, correct me if I'm wrong if this is not a best practice to follow. In the end, I need to load all these files into on-prem SQL server using SSIS.

Many thanks in advance
Shan

.NET CLI
.NET CLI
A cross-platform toolchain for developing, building, running, and publishing .NET applications.
328 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Sara Liu-MSFT 346 Reputation points Microsoft Vendor
    2021-09-22T02:52:58.877+00:00

    Dear customer, thank you for your feedback.
    According to your description, this issue is about the AWS Batch and please redirect to this appropriate forum: https://forums.aws.amazon.com/forum.jspa?forumID=240 to seek for a better support, thanks for your understanding.
    If you have any issues about the .NET CLI commands: https://video2.skills-academy.com/en-us/dotnet/core/tools/ in the future, please feel free to let us know. :)

    Best regards,
    Sara

    0 comments No comments