diff --git a/install/preview/entrypoint.sh b/install/preview/entrypoint.sh index 0da8d764941d31..9aa7deb53a9fcd 100755 --- a/install/preview/entrypoint.sh +++ b/install/preview/entrypoint.sh @@ -143,8 +143,15 @@ run_telemetry(){ sleep 100 # indefinitely wait for Gitpod pods to be ready kubectl wait --timeout=-1s --for=condition=ready pod -l app=gitpod,component!=migrations - # manually tun the cronjob - kubectl create job gitpod-telemetry-init --from=cronjob/gitpod-telemetry + echo "Gitpod pods are ready" + # honour DO_NOT_TRACK if set + if [ -n "${DO_NOT_TRACK}" ] && [ "${DO_NOT_TRACK}" -eq 1 ]; then + # suspend the cronjob + kubectl patch cronjobs gitpod-telemetry -p '{"spec" : {"suspend" : true }}' + else + # manually run the cronjob + kubectl create job gitpod-telemetry-init --from=cronjob/gitpod-telemetry + fi } run_telemetry 2>&1 & diff --git a/install/preview/prettylog/main.go b/install/preview/prettylog/main.go index cfecf8a6f3c8e4..858783b1960da1 100644 --- a/install/preview/prettylog/main.go +++ b/install/preview/prettylog/main.go @@ -24,7 +24,7 @@ var msgs = []struct { {Msg: "preparing system", Success: "extracting images to download ahead"}, {Msg: "downloading images", Success: "--output-split-files"}, {Msg: "preparing Gitpod preview installation", Success: "rm -rf /var/lib/rancher/k3s/server/manifests/gitpod"}, - {Msg: "starting Gitpod", Success: "gitpod-telemetry-init"}, + {Msg: "starting Gitpod", Success: "Gitpod pods are ready"}, {Msg: fmt.Sprintf("Gitpod is running. Visit https://%s to access the dashboard", os.Getenv("DOMAIN"))}, }