|
|
|
@ -80,16 +80,20 @@ headers. This can expose sensitive information in your logs.") |
|
|
|
|
extra-tunnel-options |
|
|
|
|
token http2-origin? post-quantum? |
|
|
|
|
extra-options) |
|
|
|
|
(let ((tunnel-options |
|
|
|
|
(list "--no-autoupdate" "--metrics" metrics "--loglevel" log-level))) |
|
|
|
|
(list (shepherd-service |
|
|
|
|
(documentation "Run cloudflared.") |
|
|
|
|
(provision '(cloudflare-tunnel)) |
|
|
|
|
(requirement '(networking)) |
|
|
|
|
(start #~(make-forkexec-constructor |
|
|
|
|
(list #$cloudflared "tunnel" #$@tunnel-options |
|
|
|
|
(list #$cloudflared |
|
|
|
|
"tunnel" |
|
|
|
|
"--no-autoupdate" |
|
|
|
|
"--metrics" #$metrics |
|
|
|
|
"--loglevel" #$log-level |
|
|
|
|
#$@extra-tunnel-options |
|
|
|
|
"run" "--token" #$token |
|
|
|
|
|
|
|
|
|
"run" |
|
|
|
|
"--token" #$token |
|
|
|
|
#$@(if http2-origin? |
|
|
|
|
'("--http2-origin") |
|
|
|
|
'()) |
|
|
|
@ -100,7 +104,7 @@ headers. This can expose sensitive information in your logs.") |
|
|
|
|
#:user "cloudflared" |
|
|
|
|
#:group "cloudflared" |
|
|
|
|
#:log-file #$log-file)) |
|
|
|
|
(stop #~(make-kill-destructor)))))))) |
|
|
|
|
(stop #~(make-kill-destructor))))))) |
|
|
|
|
|
|
|
|
|
(define cloudflare-tunnel-service-type |
|
|
|
|
(service-type |
|
|
|
|