30 lines
565 B
Makefile
30 lines
565 B
Makefile
|
|
release: deps templ
|
|
GIN_MODE=release go build -v -x -buildvcs=true .
|
|
|
|
dev: templ
|
|
go build .
|
|
./filegate -p=false --localfs=./storage
|
|
|
|
clean:
|
|
rm -f filegate
|
|
# rm -f config.yaml
|
|
rm -f db.sqlite
|
|
rm -rf storage/
|
|
|
|
templ:
|
|
rm -f web/templates/*_templ.go
|
|
templ fmt .
|
|
templ generate
|
|
|
|
deps:
|
|
go mod download
|
|
go mod tidy
|
|
|
|
install:
|
|
sudo useradd -d /var/lib/filegate -c"Filegate Service User" -rmUF filegate
|
|
sudo mkdir -p /etc/filegate
|
|
sudo install -o root -g filegate -m 750 ./filegate /usr/local/filegate
|
|
./filegate genconfig
|
|
sudo cp config.yaml /etc/filegate
|