/s3www

Serve static files from any S3 compatible object storage services (Let's Encrypt ready)

Primary LanguageGoApache License 2.0Apache-2.0

s3www

Serve static files from any S3 compatible object storage endpoints.

Table of Contents

Install

Released binaries are available here, or you can compile yourself from source.

GO111MODULE=on go get github.com/harshavardhana/s3www

Binary

Make sure you have index.html under mysite

s3www -endpoint "https://s3.amazonaws.com" -accessKey "accessKey" \
      -secretKey "secretKey" -bucket "mysite"

s3www: Started listening on http://127.0.0.1:8080

Point your web browser to http://127.0.0.1:8080 ensure your s3www is serving your index.html successfully.

Container

Make sure you have index.html under mysite

podman run --rm -p 8080:8080 y4m4/s3www:latest \
      -endpoint "https://s3.amazonaws.com" \
      -accessKey "accessKey" \
      -secretKey "secretKey" \
      -bucket "mysite" \
      -address "0.0.0.0:8080"

s3www: Started listening on http://0.0.0.0:8080

Point your web browser to http://127.0.0.1:8080 ensure your s3www is serving your index.html successfully.

Auto TLS

Make sure you have index.html under mysite

s3www -endpoint "https://s3.amazonaws.com" -accessKey "accessKey" \
      -secretKey "secretKey" -bucket "mysite" \
      -lets-encrypt -address "example.com"

s3www: Started listening on https://example.com

Point your web browser to https://example.com ensure your s3www is serving your index.html successfully.

License

This project is distributed under the Apache License, Version 2.0, see LICENSE for more information.

Buy me a coffeeBuy me a coffee