Minio Go Library for Amazon S3 compatible cloud storage
Go to file
Harshavardhana cff99100a5 minio-go: Move request into Client, rename API as Client.
- This cleanup merges newRequest into Client and uses httpClient
  instance properly in a single Client object context.
- This cleanup also ensures that we use getBucketLocation, inside
  request constructor to avoid the overkill of each requests handling
  them.
- ListBuckets now replies a list of buckets not an iterator.
- Remove mocked tests, we will write them through functional tests.
- ListObjectsPartsRecursive now cleans itself up in putParts through
  read channel.
2015-12-16 21:03:24 -08:00
examples minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
.gitignore Remove erroneous binary 2015-09-21 02:28:03 -07:00
.travis.yml Remove dummy code, bump travis to Golang 1.5.1 2015-09-21 02:25:41 -07:00
CONTRIBUTING.md Update CONTRIBUTING.md 2015-05-27 18:56:48 -07:00
INSTALLGO.md Create INSTALLGO.md 2015-11-28 09:00:21 +05:30
LICENSE Object storage library - first commit 2015-05-01 23:59:31 -07:00
MAINTAINERS.md minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
README.md minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-definitions.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-error-response.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-get.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-list.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-presigned.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-put-bucket.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-put-object.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-remove.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api-s3-definitions.go More cleanup and restructuring. 2015-12-13 02:26:38 -08:00
api-stat.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api_functional_test.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
api_private_test.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
appveyor.yml build: Do not download go1.5.1 for appveyor builds. 2015-12-02 15:44:37 -08:00
bucket-acl.go doc: More simplification 2015-11-09 20:39:02 -08:00
bucket-cache.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
common-methods.go putObject: Re-introduce size and this time with size of -1 we do multipart upload of sizes 5GB 2015-11-28 21:57:46 -08:00
parts-manager.go cleanup: Major rewrite of most of the components 2015-12-11 00:04:09 -08:00
post-policy.go minio-go: Go API cleanup. 2015-12-03 11:44:06 -08:00
request-signature-v2.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
request-signature-v4.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00
signature-type.go More cleanup and restructuring. 2015-12-13 02:26:38 -08:00
tempfile.go More cleanup and restructuring. 2015-12-13 02:26:38 -08:00
utils.go minio-go: Move request into Client, rename API as Client. 2015-12-16 21:03:24 -08:00

README.md

Minio Go Library for Amazon S3 Compatible Cloud Storage Gitter

Description

Minio Go library is a simple client library for S3 compatible cloud storage servers. Supports AWS Signature Version 4 and 2. AWS Signature Version 4 is chosen as default.

List of supported cloud storage providers.

  • AWS Signature Version 4

    • Amazon S3
    • Minio
  • AWS Signature Version 2

    • Google Cloud Storage (Compatibility Mode)
    • Openstack Swift + Swift3 middleware
    • Ceph Object Gateway
    • Riak CS

Install

If you do not have a working Golang environment, please follow Install Golang.

$ go get github.com/minio/minio-go

Example

ListBuckets()

This example shows how to List your buckets.

package main

import (
	"log"

	"github.com/minio/minio-go"
)

func main() {
	// Requests are always secure (HTTPS) by default. Set insecure=true to enable insecure (HTTP) access.
	// This boolean value is the last argument for New().

	// New returns an Amazon S3 compatible client object. API copatibality (v2 or v4) is automatically
	// determined based on the Endpoint value.
	s3Client, err := minio.New("s3.amazonaws.com", "YOUR-ACCESS-KEY-HERE", "YOUR-SECRET-KEY-HERE", false)
	if err != nil {
	    log.Fatalln(err)
	}
	buckets, err := s3Client.ListBuckets()
	if err != nil {
		log.Fatalln(err)
	}
	for _, bucket := range buckets {
		log.Println(bucket)
	}
}

Documentation

Bucket Operations.

Object Operations.

Presigned Operations.

API Reference

GoDoc

Contribute

Contributors Guide

Build Status Build status