mirror of
https://github.com/yusing/godoxy.git
synced 2026-04-22 08:48:43 +02:00
run as non root and non host network mode
This commit is contained in:
8
Makefile
8
Makefile
@@ -45,9 +45,11 @@ get:
|
||||
build:
|
||||
mkdir -p bin
|
||||
go build ${BUILD_FLAGS} -o bin/godoxy ./cmd
|
||||
if [ $(shell id -u) -eq 0 ]; \
|
||||
then setcap CAP_NET_BIND_SERVICE=+eip bin/godoxy; \
|
||||
else sudo setcap CAP_NET_BIND_SERVICE=+eip bin/godoxy; \
|
||||
if which setcap; then \
|
||||
if [ $(shell id -u) -eq 0 ]; \
|
||||
then setcap CAP_NET_BIND_SERVICE=+eip bin/godoxy; \
|
||||
else sudo setcap CAP_NET_BIND_SERVICE=+eip bin/godoxy; \
|
||||
fi \
|
||||
fi
|
||||
|
||||
run:
|
||||
|
||||
Reference in New Issue
Block a user