gofsud

module
v0.0.0-...-1063e65 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 11, 2020 License: MIT

README

gofsud

The smallest possible HTTP upload and download file server. GoFSUD stands for Golang File Server Upload & Download.

API

Quick start

Docker
$ docker run -it --rm --init \
    --user ${UID} \
    --publish "8080:8080" \
    --env GOFSUD_DIRECTORY='/web' \
    --volume /tmp/gofsud:/web \
    theagentk/gofsud:latest
Golang

Follow the development instructions, and then run:

$ mage bin:run

Development

Requirements
  • Install Go >= 1.15.3

  • Install mage:

    $ git clone https://github.com/magefile/mage /tmp/mage
    $ cd /tmp/mage
    $ go run bootstrap.go
    
  • For image building, you can define the following environment variables:

    Name Default Description
    GO_IMAGE_VERSION 1.15.3-alpine Base Golang docker image version to use for building
    DISTROLESS_IMAGE gcr.io/distroless/base-debian10 Base image to use for running the app
    DISTROLESS_VERSION nonroot Version of the image for running the app
    IMAGE_DESTINATION theagentk/gofsud Name of the resulting image to build
Bootstrap
  • Install tools
    $ mage install
    
  • Install dependencies and run sanity check
    $ mage
    

Directories

Path Synopsis
app

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL