Browse Source

Update readme

tags/v1.0.0
Remco 7 years ago
parent
commit
48bcfbe0bc
1 changed files with 30 additions and 18 deletions
  1. +30
    -18
      README.md

+ 30
- 18
README.md View File

@@ -1,4 +1,4 @@
# transfer.sh [![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/dutchcoders/transfer.sh?utm_source=badge&utm_medium=badge&utm_campaign=&utm_campaign=pr-badge&utm_content=badge) [![Go Report Card](https://goreportcard.com/badge/dutchcoders/transfer.sh)](https://goreportcard.com/report/dutchcoders/transfer.sh) [![Docker pulls](https://img.shields.io/docker/pulls/transfer.sh/transfer.sh.svg)](https://hub.docker.com/r/transfer.sh/transfer.sh/) [![Build Status](https://travis-ci.org/dutchcoders/transfer.sh.svg?branch=master)](https://travis-ci.org/dutchcoders/transfer.sh)
# transfer.sh [![Gitter](https://badges.gitter.im/Join%20Chat.svg)](https://gitter.im/dutchcoders/transfer.sh?utm_source=badge&utm_medium=badge&utm_campaign=&utm_campaign=pr-badge&utm_content=badge) [![Go Report Card](https://goreportcard.com/badge/github.com/dutchcoders/transfer.sh)](https://goreportcard.com/report/github.com/dutchcoders/transfer.sh) [![Docker pulls](https://img.shields.io/docker/pulls/transfer.sh/transfer.sh.svg)](https://hub.docker.com/r/transfer.sh/transfer.sh/) [![Build Status](https://travis-ci.org/dutchcoders/transfer.sh.svg?branch=master)](https://travis-ci.org/dutchcoders/transfer.sh)

Easy and fast file sharing from the command-line. This code contains the server with everything you need to create your own instance.

@@ -34,30 +34,42 @@ alias transfer=transfer
$ transfer test.txt
```

## Development
## Usage

```
npm install
bower install
Parameter | Description | Value | Environment
--- | --- | ---
listener | port to use for http (:80) |
profile-listener | port to use for profiler (:6060)|
force-https | redirect to https | false
tls-listener | port to use for https (:443) |
tls-cert-file | path to tls certificate |
tls-private-key | path to tls private key |
temp-path | path to temp folder | system temp
web-path | path to static web files (for development) |
provider | which storage provider to use | (s3 or local)
aws-access-key | aws access key | | AWS_ACCESS_KEY
aws-secret-key | aws access key | | AWS_SECRET_KEY
bucket | aws bucket | | BUCKET
basedir | path storage for local provider| |
lets-encrypt-hosts | hosts to use for lets encrypt certificates (comma seperated) | |
log | path to log file| |

If you want to use TLS using lets encrypt certificates, set lets-encrypt-hosts to your domain, set tls-listener to :443 and enable force-https.

If you want to use TLS using your own certificates, set tls-listener to :443, force-https, tls-cert=file and tls-private-key.

go get github.com/PuerkitoBio/ghost/handlers
go get github.com/gorilla/mux
go get github.com/dutchcoders/go-clamd
go get github.com/goamz/goamz/s3
go get github.com/goamz/goamz/aws
go get github.com/golang/gddo/httputil/header
go get github.com/kennygrant/sanitize
## Development

grunt serve
grunt build
Make sure your GOPATH is set correctly.

go run transfersh-server/*.go -provider=local --port 8080 --temp=/tmp/ --basedir=/tmp/
```
go run main.go -provider=local --listener :8080 --temp-path=/tmp/ --basedir=/tmp/
```

## Build

```
go build -o transfersh-server *.go
go build -o transfersh main.go
```

## Docker
@@ -65,8 +77,8 @@ go build -o transfersh-server *.go
For easy deployment we've enabled Docker deployment.

```
docker build -t transfersh .
docker run --publish 8080:8080 --rm transfersh --provider local --basedir /tmp/
docker build -t dutchcoders/transfer.sh:latest .
docker run --publish 8080:8080 dutchcoders/transfer.sh:latest --provider local --basedir /tmp/
```

## Contributions


Loading…
Cancel
Save