Go to file
Torjus Håkestad 1c4baab3af
Some checks failed
ci/woodpecker/push/woodpecker Pipeline failed
Fix gitignore
2022-01-13 18:46:46 +01:00
actions Rename module 2022-01-13 18:40:15 +01:00
certs Rename module 2022-01-13 18:40:15 +01:00
config Rename module 2022-01-13 18:40:15 +01:00
ezshare Fix gitignore 2022-01-13 18:46:46 +01:00
pb Rename module 2022-01-13 18:40:15 +01:00
protos Rename module 2022-01-13 18:40:15 +01:00
scripts Initial commit 2021-12-03 23:05:29 +01:00
server Rename module 2022-01-13 18:40:15 +01:00
store Rename module 2022-01-13 18:40:15 +01:00
.gitignore Fix gitignore 2022-01-13 18:46:46 +01:00
.goreleaser.yaml Add goreleaser 2022-01-13 18:37:39 +01:00
.woodpecker.yml Fix pipeline 2022-01-13 18:44:33 +01:00
Dockerfile Generate certificates if they don't exist 2021-12-08 20:32:10 +01:00
ezshare.example.toml Allow updating config from env 2021-12-08 11:43:41 +01:00
ezshare.minimal.env Generate certificates if they don't exist 2021-12-08 20:32:10 +01:00
go.mod Rename module 2022-01-13 18:40:15 +01:00
go.sum Add proper logging 2021-12-06 07:55:30 +01:00
main.go Rename module 2022-01-13 18:40:15 +01:00
README.md Rename module 2022-01-13 18:40:15 +01:00

status-badge

ezshare

Server

Running a server using docker:

# First, build the image
docker build -t ezshare:latest .

Copy config file to /var/ezshare/ezshare.toml (or see ezshare.minimal.env to see how to set config-values using envvars)
# Run the server
docker run --rm -d -v /var/ezshare:/data -e EZSHARE_CONFIG=/data/ezshare.toml ezshare:latest

Client

Compile the client:

go build -o ezshare cmd/ezshare.go

Generate client config, and fetch needed certificates:

./ezshare client login --overwrite "https://ezshare.example.org"
username: admin
password: 
NAME:
   ezshare client - Client commands

USAGE:
   ezshare client command [command options] [arguments...]

COMMANDS:
   get          Get file with id
   upload       Upload file(s)
   delete       Delete file with id
   list         List files
   config-init  Initialize default config
   help, h      Shows a list of commands or help for one command

OPTIONS:
   --addr value  Address of server.
   --help, -h    show help (default: false)

Development

Recompile proto-files

protoc --go_out=. --go-grpc_out=. --go_opt=module=git.t-juice.club/torjus/ezshare --go-grpc_opt=module=git.t-juice.club/torjus/ezshare protos/ezshare.proto