feat: add /files/{file} GET and DELETE methods
This commit is contained in:
parent
7ca416e43e
commit
4a4a0a2149
7 changed files with 252 additions and 60 deletions
39
README.md
Normal file
39
README.md
Normal file
|
|
@ -0,0 +1,39 @@
|
|||
# sfu
|
||||
|
||||
simple requirementsless, authenticationless file upload server
|
||||
|
||||
## prod version
|
||||
|
||||
WIP
|
||||
|
||||
## dev version
|
||||
|
||||
### using docker
|
||||
|
||||
1. take a look at [docker-compose](docker-compose.yml) and modify the envvars accordingly. the default values **should work** as long as you're ok with a `files/` folder being created and **your user UID and GID are 1000**. if for some reason you need other ids, please add them like this:
|
||||
|
||||
```docker-compose
|
||||
...
|
||||
|
||||
app:
|
||||
build:
|
||||
context: .
|
||||
target: run_dev
|
||||
environment:
|
||||
- SFU_PORT=80
|
||||
- SFU_FILES_DIR=./files
|
||||
- gid=1234
|
||||
- uid=1234
|
||||
...
|
||||
```
|
||||
|
||||
### dockerless
|
||||
|
||||
1. sfu needs two envvars to be set
|
||||
- `SFU_PORT`: the port to listen on
|
||||
- `SFU_FILES_DIR`: the directory to store files in
|
||||
2. run the server
|
||||
```shell
|
||||
go build
|
||||
SFU_PORT=80 SFU_FILES_DIR=./files ./main
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue