AWS CLI is the official command line interface of AWS., Their official site describe this as below
The AWS Command Line Interface (CLI) is a unified tool to manage your AWS services. With just one tool to download and configure, you can control multiple AWS services from the command line and automate them through scripts.
Install AWS CLI in ubuntu
Follow the commands to get this installed on your server
]# curl “https://awscli.amazonaws.com/awscli-exe-linux-x86_64.zip” -o “awscliv2.zip”
]# unzip awscliv2.zip
]# sudo ./aws/install
Confirm AWS CLI Installation
]# aws –version
aws-cli/1.18.69 Python/3.8.2 Linux/5.4.0-40-generic botocore/1.16.19
List Buckets
]# aws s3 ls
Copy Files from Local System to S3 Buckets
]# aws s3 cp filename.txt s3://mybucket/fileName.txt
Copy a Local Folder to AWS S3 bucket
]# aws s3 sync ./folder s3://mybucket/
Copy a Local File to a folder inside AWS S3 bucket
]# aws s3 cp filename.txt s3://mybucket/myfolder/fileName.txt
Note : Replace mybucket with your bucket name , and myfolder with your sub folder name