webhook
webhook copied to clipboard
New webhook version 2.5.0-2 doesn't support many params
Hi,
I have installed new webhook version which does not support many parameters to configure like (ex. -logfile, -setgid, -setuid) etc.
Can somebody tell me how to setup above params? I need to run the script with my user and with all the logs file
Here is the latest
user@xxxx:~$ /usr/bin/webhook -help Usage of /usr/bin/webhook: -cert string path to the HTTPS certificate pem file (default "cert.pem") -header value response header to return, specified in format name=value, use multiple times to set multiple headers -hooks string path to the json file containing defined hooks the webhook should serve (default "hooks.json") -hotreload watch hooks file for changes and reload them automatically -ip string ip the webhook should serve hooks on (default "0.0.0.0") -key string path to the HTTPS certificate private key pem file (default "key.pem") -nopanic do not panic if hooks cannot be loaded when webhook is not running in verbose mode -port int port the webhook should serve hooks on (default 9000) -secure use HTTPS instead of HTTP -urlprefix string url prefix to use for served hooks (protocol://yourserver:port/PREFIX/:hook-id) (default "hooks") -verbose show verbose output
Old version
user@xxx:~$ /usr/bin/webhook -help Usage of /usr/bin/webhook: -cert string path to the HTTPS certificate pem file (default "cert.pem") -cipher-suites string comma-separated list of supported TLS cipher suites -debug show debug output -header value response header to return, specified in format name=value, use multiple times to set multiple headers -hooks value path to the json file containing defined hooks the webhook should serve, use multiple times to load from different files -hotreload watch hooks file for changes and reload them automatically -http-methods string set default allowed HTTP methods (ie. "POST"); separate methods with comma -ip string ip the webhook should serve hooks on (default "0.0.0.0") -key string path to the HTTPS certificate private key pem file (default "key.pem") -list-cipher-suites list available TLS cipher suites -logfile string send log output to a file; implicitly enables verbose logging -max-multipart-mem int maximum memory in bytes for parsing multipart form data before disk caching (default 1048576) -nopanic do not panic if hooks cannot be loaded when webhook is not running in verbose mode -pidfile string create PID file at the given path -port int port the webhook should serve hooks on (default 9000) -secure use HTTPS instead of HTTP -setgid int set group ID after opening listening port; must be used with setuid -setuid int set user ID after opening listening port; must be used with setgid -template parse hooks file as a Go template -tls-min-version string minimum TLS version (1.0, 1.1, 1.2, 1.3) (default "1.2") -urlprefix string url prefix to use for served hooks (protocol://yourserver:port/PREFIX/:hook-id) (default "hooks") -verbose show verbose output -version display webhook version and quit -x-request-id use X-Request-Id header, if present, as request ID -x-request-id-limit int truncate X-Request-Id header to limit; default no limit
Thanks,
What does webhook -version show?
test@xxx:~$ webhook -version flag provided but not defined: -version
The version is
test@xxx:~$ sudo dpkg -l | grep -i webhook ii webhook 2.5.0-2 amd64 Small server for creating HTTP endpoints (hooks)
I am running ubuntu 18.04. so i think this is the latest repo, how can i get the latest webhook on ubuntu18.04?
Thanks,
Tejas
I have fixed this with installing via release.
"#installing webhook binary", "wget https://github.com/adnanh/webhook/releases/download/2.8.0/webhook-linux-amd64.tar.gz --directory-prefix=/root/",
but i am still not sure why setuid and setgid not working.
Here is the error.
[webhook] error dropping privileges: setuid and setgid not supported on linux
Version 2.8.0 does not support setuid/segid (see the explicit build tag: !linux).
This feature is very needed when Webhook is running as a non-privileged user serving via HTTPS as the cert keys are usually owned by root and have 0600 permissions => privileges can't be set via systemd unit and Webhook can't read the cert key.