feat: add systemd installation

This commit is contained in:
2025-05-06 13:40:55 +02:00
parent 3bbb689cac
commit c2b483d20d
6 changed files with 56 additions and 27 deletions

View File

@@ -10,8 +10,18 @@ build:
mkdir -p bin
env GOOS=linux GOARCH=${ARCH} go build -o bin/rcond-${ARCH} ./cmd/rcond/main.go
install:
sudo mkdir -p /etc/rcond
sudo mkdir -p /var/rcond
sudo cp config/rcond.yaml /etc/rcond/config.yaml
sudo cp bin/rcond-${ARCH} /usr/local/bin/rcond
sudo cp systemd/rcond.service /etc/systemd/system/rcond.service
sudo systemctl daemon-reload
sudo systemctl enable rcond
sudo systemctl start rcond
run:
bin/rcond-${ARCH} -config config.yaml
bin/rcond-${ARCH} -config config/rcond.yaml
dev:
RCOND_ADDR=127.0.0.1:8080 \