HowTo: Install AWS CLI - Amazon Simple Storage Service (S3) - s3curl.pl
The Amazon S3 Authentication Tool for Curl, s3curl.pl
is used to interface with Amazon S3, allowing you to upload to and download from the service.
s3curl.pl
requires Perl 5.6.0 or later, curl, and the following Perl modules:
Digest::HMAC_SHA1
FindBin
MIME::Base64
Getopt::Long
This tool does not require environment variables to be set, but it does use the file ~/.s3curl
if you do not pass the credentials on the command line. It is recommended to use ~/.s3curl
as passing the credentials on the command line is not safe. To set up the ~/.s3curl
file, see: HowTo: Install AWS CLI - Security Credentials.
Install Script
If you’re running Linux, this script will do everything this article covers: install_s3curl.sh from our aws_scripts collection. Be sure to run it as root or use sudo
.
Git Repository
Checkout the repository. This only needs to be done once throughout this series of articles.
Console - user@hostname ~ $
1
git clone https://bitbucket.org/dowdandassociates/aws_scripts.git
Run install script
Console - user@hostname ~ $
1
sudo aws_scripts/install_aws_cli/install_s3curl.sh
Direct Download of Script
Console - user@hostname ~ $
1
curl -L https://bitbucket.org/dowdandassociates/aws_scripts/raw/master/install_aws_cli/install_s3curl.sh | sudo bash
Install Process
Create the directory in which to download the software, if the folder does not already exist.
Console - root@hostname ~ #
1
mkdir -p /tmp/aws
Create the directories in which the software will be installed, if the folders do not already exist.
Console - root@hostname ~ #
1
2
mkdir -p /usr/local/share
mkdir -p /usr/local/bin
Download the software
Console - root@hostname ~ #
1
2
3
curl --silent \
--output /tmp/aws/s3-curl.zip \
http://s3.amazonaws.com/doc/s3-example-code/s3-curl.zip
Unzip the software.
Console - root@hostname ~ #
1
unzip -d /tmp/aws /tmp/aws/s3-curl.zip
Change s3curl.pl
to be able to execute.
Console - root@hostname ~ #
1
chmod 755 /tmp/aws/s3-curl/s3curl.pl
Delete any previously installed versions.
Console - root@hostname ~ #
1
rm -fR /usr/local/share/s3-curl
Move the software to the install directories.
Console - root@hostname ~ #
1
2
mv /tmp/aws/s3-curl /usr/local/share
mv /usr/local/share/s3-curl/s3curl.pl /usr/local/bin
Delete the .zip
file.
Console - root@hostname ~ #
1
rm -fR /tmp/aws/s3-curl*
s3curl.pl
should now be available to you. If not, make sure /usr/local/bin
is in your PATH
.
References
Parts in this series
- HowTo: Install AWS CLI
- HowTo: Install AWS CLI - Prerequisites
- HowTo: Install AWS CLI - Security Credentials
- HowTo: Install AWS CLI - AWS Command Line Interface
- HowTo: Install AWS CLI - Amazon Auto Scaling
- HowTo: Install AWS CLI - Amazon CloudFormation
- HowTo: Install AWS CLI - Amazon CloudFront
- HowTo: Install AWS CLI - Amazon CloudWatch
- HowTo: Install AWS CLI - Amazon ElastiCache
- HowTo: Install AWS CLI - Amazon Elastic Compute Cloud (EC2) - AMI Tools
- HowTo: Install AWS CLI - Amazon Elastic Compute Cloud (EC2) - API Tools
- HowTo: Install AWS CLI - Amazon Elastic Load Balancing (ELB)
- HowTo: Install AWS CLI - Amazon Elastic MapReduce Ruby Client
- HowTo: Install AWS CLI - Amazon Identity and Access Management (IAM)
- HowTo: Install AWS CLI - Amazon Relational Data Services (RDS)
- HowTo: Install AWS CLI - Amazon Route 53 - cli53
- HowTo: Install AWS CLI - Amazon Route 53 - dnscurl.pl
- HowTo: Install AWS CLI - Amazon Simple Email Service (SES)
- HowTo: Install AWS CLI - Amazon Simple Notification Service (SNS)
- HowTo: Install AWS CLI - Amazon Simple Storage Service (S3) - s3cmd
- HowTo: Install AWS CLI - Amazon Simple Storage Service (S3) - s3curl.pl