Skip to content

Commit

Permalink
Add goreleaser configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
Thor77 committed Feb 18, 2020
1 parent aa1c1ad commit 7300288
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 0 deletions.
41 changes: 41 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
before:
hooks:
- go mod tidy
builds:
- env:
- CGO_ENABLED=0
goos:
- linux
goarch:
- amd64
- 386
archives:
- replacements:
386: i386
amd64: x86_64
checksum:
name_template: 'checksums.txt'
snapshot:
name_template: "{{ .Tag }}-next"
changelog:
sort: asc
filters:
exclude:
- '^docs:'
- '^test:'
nfpms:
- id: deb
package_name: rtmp2hls
homepage: https://github.com/Thor77/rtmp2hls
maintainer: Thor77 <thor77 at thor77 dot org>
description: Simple rtmp server with hls output
license: MIT
formats:
- deb
bindir: /usr/bin
files:
'doc/rtmp2hls.service': '/lib/systemd/system/rtmp2hls.service'
config_files:
'config.toml': '/etc/rtmp2hls.toml'
scripts:
postinstall: 'doc/postinstall.sh'
9 changes: 9 additions & 0 deletions doc/postinstall.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/sh
if ! getent group rtmp2hls > /dev/null 2>&1 ; then
addgroup --system rtmp2hls --quiet
fi
if ! id rtmp2hls > /dev/null 2>&1 ; then
adduser --system --no-create-home \
--ingroup rtmp2hls --disabled-password --shell /bin/false \
rtmp2hls
fi

0 comments on commit 7300288

Please sign in to comment.