cloud storage
S3
Amazon S3 or Amazon Simple Storage Service is a service offered by Amazon Web Services (AWS) that provides object storage through a web service interface.
Example object url
http://doc.s3.amazonaws.com/2006-03-01/AmazonS3.wsdl
S3 advantages ?
Ceph (pronounced /ˈsɛf/) is a free-software storage platform, implements object storage on a single distributed computer cluster, and provides interfaces for object-, block- and file-level storage. Ceph aims primarily for completely distributed operation without a single point of failure, scalable to the exabyte level, and freely available.
https://s3tools.org/s3cmd
S3cmd is a free command line tool and client for uploading, retrieving and managing data in Amazon S3 and other cloud storage service providers that use the S3 protocol, such as Google Cloud Storage or DreamHost DreamObjects. It is best suited for power users who are familiar with command line programs. It is also ideal for batch scripts and automated backup to S3, triggered from cron, etc.
s3cmd usage
The s3cmd configuration file is named .s3cfg and it is located in the user's home directory, e.g. /home/username/ ($HOME).
CORS
s3cmd setcors cors.xml s3://krab-stage
<CORSConfiguration>
<CORSRule>
<AllowedOrigin>*</AllowedOrigin>
<AllowedMethod>GET</AllowedMethod>
<AllowedHeader>*</AllowedHeader>
<MaxAgeSeconds>3000</MaxAgeSeconds>
<ExposeHeader>x-server-side-encryption</ExposeHeader>
</CORSRule>
</CORSConfiguration>
Multiple configs
s3cmd ls s3://bucketname -c ~/.second-s3cfg
Using S3 with Django
- boto3
- django-storages
The end
cloud storage
By zqzak
cloud storage
- 201