From c1c8063d599fccf385b3b9f21a7a14e5818fbe71 Mon Sep 17 00:00:00 2001 From: kekskurse Date: Mon, 20 Sep 2021 11:44:27 +0200 Subject: [PATCH] Release stuff --- .goreleaser.yml | 18 +++++++++++++++--- init/http-server-status.service | 17 +++++++++++++++++ scripts/postinstall.sh | 2 ++ 3 files changed, 34 insertions(+), 3 deletions(-) create mode 100644 init/http-server-status.service create mode 100644 scripts/postinstall.sh diff --git a/.goreleaser.yml b/.goreleaser.yml index da53960..f8a5b81 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -20,8 +20,6 @@ archives: amd64: x86_64 checksum: name_template: 'checksums.txt' -snapshot: - name_template: "{{ .Tag }}-next" changelog: sort: asc filters: @@ -32,4 +30,18 @@ gitea_urls: api: https://git.keks.cloud/api/v1/ download: https://git.keks.cloud # set to true if you use a self-signed certificate - skip_tls_verify: false \ No newline at end of file + skip_tls_verify: false + +nfpms: + id: "http-server-status" + package_name: "http-server-status" + vendor: kekskurse + homepage: https://git.keks.cloud/kekskurse/http-server-status + maintainer: hello@kekskurse.de + description: Stauts Page for Server + license: Apache 2.0 + formats: + - deb + contents: + - src: init/http-server-status.service + dst: /etc/systemd/system/http-server-status.service \ No newline at end of file diff --git a/init/http-server-status.service b/init/http-server-status.service new file mode 100644 index 0000000..c5bce00 --- /dev/null +++ b/init/http-server-status.service @@ -0,0 +1,17 @@ +[Unit] +Description=Go Mail Admin +After=syslog.target + +[Service] +Type=simple +User=root +ExecStart=/usr/local/bin/http-server-status +SyslogIdentifier=http-server-status +StandardOutput=syslog +StandardError=syslog +Restart=always +RestartSec=3 + + +[Install] +WantedBy=multi-user.target \ No newline at end of file diff --git a/scripts/postinstall.sh b/scripts/postinstall.sh new file mode 100644 index 0000000..6061044 --- /dev/null +++ b/scripts/postinstall.sh @@ -0,0 +1,2 @@ +systemctl daemon-reload +systemctl restart http-server-status \ No newline at end of file