/S3

An open-source Node.js implementation of a server handling the S3 protocol

Primary LanguageJavaScriptApache License 2.0Apache-2.0

S3 Server

S3 Server logo

CircleCI Scality CI

Learn more at s3.scality.com

Contributing

In order to contribute, please follow the Contributing Guidelines.

Installation

Clone source code

git clone https://github.com/scality/S3.git

Install js dependencies

Go to the ./S3 folder,

npm install

Run it with a file backend

npm start

This starts an S3 server on port 8000. The default access key is accessKey1 with a secret key of verySecretKey1.

By default the metadata files will be saved in the localMetadata directory and the data files will be saved in the localData directory within the ./S3 directory on your machine. These directories have been pre-created within the repository. If you would like to save the data or metadata in different locations of your choice, you must specify them. So, when starting the server:

export S3DATAPATH="/s3/myFavoriteDataPath"
export S3METADATAPATH="/s3/myFavoriteMetadataPath"
npm start

Run it with an in-memory backend

npm run mem_backend

This starts an S3 server on port 8000. The default access key is accessKey1 with a secret key of verySecretKey1.

Testing

You can run the unit tests with the following command:

npm test

You can run the linter with:

npm run lint

You can run local functional tests with:

npm run mem_backend &
npm run ft_test

s3cmd versions

If using s3cmd as a client to S3 be aware that v4 signature format is buggy in s3cmd versions < 1.6.1.