mirror of
https://github.com/pentoo/pentoo-overlay
synced 2026-05-04 18:40:19 +02:00
go-exploitdb: change default log dir path
This commit is contained in:
parent
ba06dc26e4
commit
3c5022dfac
3 changed files with 16 additions and 6 deletions
12
dev-go/go-exploitdb/files/change_default_logdir.patch
Normal file
12
dev-go/go-exploitdb/files/change_default_logdir.patch
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
diff -ur a/src/github.com/mozqnet/go-exploitdb/util/util.go b/src/github.com/mozqnet/go-exploitdb/util/util.go
|
||||
--- a/src/github.com/mozqnet/go-exploitdb/util/util.go 2019-09-11 12:36:44.000000000 +0300
|
||||
+++ b/src/github.com/mozqnet/go-exploitdb/util/util.go 2019-09-15 09:28:51.065415171 +0300
|
||||
@@ -33,7 +33,7 @@
|
||||
|
||||
// GetDefaultLogDir :
|
||||
func GetDefaultLogDir() string {
|
||||
- defaultLogDir := "/var/log/go-exploitdb"
|
||||
+ defaultLogDir := "/var/log/vuls"
|
||||
if runtime.GOOS == "windows" {
|
||||
defaultLogDir = filepath.Join(os.Getenv("APPDATA"), "go-exploitdb")
|
||||
}
|
||||
|
|
@ -26,8 +26,4 @@ pidfile="/run/${RC_SVCNAME}.pid"
|
|||
start_stop_daemon_args="--quiet -1 ${GEX_LOGDIR}/${RC_SVCNAME}.log -2 ${GEX_LOGDIR}/${RC_SVCNAME}.log"
|
||||
retry="TERM/25/KILL/5"
|
||||
|
||||
depend() {
|
||||
need net
|
||||
}
|
||||
|
||||
# vim: set ft=gentoo-init-d ts=4 :
|
||||
|
|
|
|||
|
|
@ -174,17 +174,19 @@ src_prepare() {
|
|||
-i "${T}"/go-exploitdb.initd || die
|
||||
fi
|
||||
|
||||
eapply "${FILESDIR}"/change_default_logdir.patch
|
||||
|
||||
default
|
||||
}
|
||||
|
||||
src_compile() {
|
||||
GOPATH="${WORKDIR}/${P}:$(get_golibdir_gopath)" \
|
||||
GOPATH="${S}:$(get_golibdir_gopath)" \
|
||||
GOCACHE="${T}/go-cache" \
|
||||
go build -v -work -x -ldflags="-X main.version=${PV} -s -w" ./... "${EGO_PN}" || die
|
||||
}
|
||||
|
||||
src_install() {
|
||||
GOPATH="${WORKDIR}/${P}:$(get_golibdir_gopath)" \
|
||||
GOPATH="${S}:$(get_golibdir_gopath)" \
|
||||
GOCACHE="${T}/go-cache" \
|
||||
go install -v -work -x -ldflags="-X main.version=${PV} -s -w" ./... "${EGO_PN}" || die
|
||||
|
||||
Loading…
Reference in a new issue