fix(packaging): create required directories + improve alpine service startup
This commit is contained in:
parent
1ff29ae1fb
commit
f9b8d4f243
@ -101,6 +101,18 @@ nfpms:
|
||||
file_info:
|
||||
mode: 0755
|
||||
packager: apk
|
||||
- dst: /var/lib/emissary
|
||||
type: dir
|
||||
file_info:
|
||||
mode: 0700
|
||||
- dst: /usr/share/emissary
|
||||
type: dir
|
||||
file_info:
|
||||
mode: 0700
|
||||
- dst: /var/log/emissary
|
||||
type: dir
|
||||
file_info:
|
||||
mode: 0700
|
||||
scripts:
|
||||
postinstall: "misc/packaging/common/postinstall-server.sh"
|
||||
- id: emissary-agent
|
||||
|
2
go.mod
2
go.mod
@ -14,6 +14,7 @@ require (
|
||||
github.com/golang-migrate/migrate/v4 v4.15.2
|
||||
github.com/jackc/pgx/v5 v5.2.0
|
||||
github.com/jedib0t/go-pretty/v6 v6.4.4
|
||||
github.com/lestrrat-go/jwx/v2 v2.0.8
|
||||
github.com/mitchellh/mapstructure v1.5.0
|
||||
github.com/pkg/errors v0.9.1
|
||||
github.com/qri-io/jsonschema v0.2.1
|
||||
@ -50,7 +51,6 @@ require (
|
||||
github.com/lestrrat-go/httpcc v1.0.1 // indirect
|
||||
github.com/lestrrat-go/httprc v1.0.4 // indirect
|
||||
github.com/lestrrat-go/iter v1.0.2 // indirect
|
||||
github.com/lestrrat-go/jwx/v2 v2.0.8 // indirect
|
||||
github.com/lestrrat-go/option v1.0.0 // indirect
|
||||
github.com/lib/pq v1.10.7 // indirect
|
||||
github.com/mattn/go-colorable v0.1.13 // indirect
|
||||
|
@ -1,9 +1,10 @@
|
||||
#!/sbin/openrc-run
|
||||
|
||||
command="/usr/bin/emissary"
|
||||
command_args="--config /etc/emissary/config.yml agent run"
|
||||
start_stop_daemon_args='--chdir /usr/share/emissary'
|
||||
command_args="--workdir /usr/share/emissary --config /etc/emissary/agent.yml agent run"
|
||||
supervisor=supervise-daemon
|
||||
output_log="/var/log/emissary/agent.log"
|
||||
error_log="$output_log"
|
||||
|
||||
depend() {
|
||||
need net
|
||||
|
@ -1,9 +1,14 @@
|
||||
#!/sbin/openrc-run
|
||||
|
||||
command="/usr/bin/emissary"
|
||||
command_args="--config /etc/emissary/config.yml server run"
|
||||
start_stop_daemon_args='--chdir /usr/share/emissary'
|
||||
command_args="--workdir /usr/share/emissary --config /etc/emissary/server.yml server run"
|
||||
supervisor=supervise-daemon
|
||||
output_log="/var/log/emissary/server.log"
|
||||
error_log="$output_log"
|
||||
|
||||
start_pre() {
|
||||
/usr/bin/emissary --workdir /usr/share/emissary --config /etc/emissary/server.yml server database migrate
|
||||
}
|
||||
|
||||
depend() {
|
||||
need net
|
||||
|
Loading…
Reference in New Issue
Block a user