initial commit: Artifacto v0.1
Self-hosted HTML artifact publisher. Single Go binary, SQLite metadata, HTML on disk. Features: password-protected artifacts, per-artifact expiration, admin dashboard with view metrics (privacy-preserving daily-salt visitor hash, sparklines, 30-day SVG chart, top referrers), rate-limited unlock endpoint. Packaged as a Docker image (two-stage, CGO_ENABLED=0, pure-Go SQLite). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
This commit is contained in:
24
Makefile
Normal file
24
Makefile
Normal file
@@ -0,0 +1,24 @@
|
||||
.PHONY: build run test docker-build docker-run tidy clean
|
||||
|
||||
BIN := bin/artifacto
|
||||
|
||||
build:
|
||||
CGO_ENABLED=0 go build -ldflags="-s -w" -o $(BIN) ./cmd/artifacto
|
||||
|
||||
run: build
|
||||
ADMIN_PASSWORD=dev SESSION_SECRET=$$(openssl rand -hex 32) BASE_URL=http://localhost:3000 DATA_DIR=./data $(BIN)
|
||||
|
||||
test:
|
||||
go test ./...
|
||||
|
||||
tidy:
|
||||
go mod tidy
|
||||
|
||||
docker-build:
|
||||
docker build -t artifacto:latest .
|
||||
|
||||
docker-run: docker-build
|
||||
docker compose up -d
|
||||
|
||||
clean:
|
||||
rm -rf bin data
|
||||
Reference in New Issue
Block a user