Git Product home page Git Product logo

s3-cdn's Introduction

S3-CDN

Lightweight CDN server (NGINX) for S3-Backend (e.g. minio)

Docker: https://hub.docker.com/r/indece/s3-cdn

Inspired by https://github.com/silinternational/docker-sync-with-s3

Usage

With Amazon AWS:

docker run -p 8080:8080 -e ACCESS_KEY=my-accesskey -e SECRET_KEY=my-secretkey -e SOURCE_PATH='s3://my-s3-bucket/' indece/s3-cdn:latest

With Minio:

docker run -p 8080:8080 -e ACCESS_KEY=my-accesskey -e SECRET_KEY=my-secretkey -e SOURCE_PATH='s3://my-s3-bucket/' -e S3SYNC_ARGS="--endpoint-url=http://myminioserver:9000" indece/s3-cdn:latest

Opens a port on 8080 and serves the files from the bucket

Important: Clones all files from the SOURCE_PATH to /data, even if a file is not accessed via HTTP.

Environment variables

Variable Required Default Description
ACCESS_KEY yes S3-Access-Key
SECRET_KEY yes S3-Secret-Key
SOURCE_PATH yes Source-Path for s3 sync (e.g. 's3://my-bucket-name/')
INTERVAL "15m" Interval for s3 sync
S3SYNC_ARGS "" Extra options passed to aws-cli for s3 sync

Health checks

The path /health always returns 200 ok when nginx is running (this doesn't verify if the s3-sync is ok).

s3-cdn's People

Contributors

indece-official avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.