From ecab453e8bda015d6c1546526be93822cb8da5f2 Mon Sep 17 00:00:00 2001 From: Timmo Date: Thu, 18 Apr 2019 10:45:19 +0100 Subject: [PATCH] :hammer: Add disable telemetry as an option --- README.md | 7 ++++++- vscode/config.json | 4 +++- vscode/rootfs/etc/services.d/code/run | 5 ++++- 3 files changed, 13 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 050ac9a..60c9371 100644 --- a/README.md +++ b/README.md @@ -70,7 +70,8 @@ Example add-on configuration: ], "init_commands": [ "ls -la" - ] + ], + "disable_telemetry": false } ``` @@ -127,6 +128,10 @@ Customize your VSCode environment even more with the `init_commands` option. Add one or more shell commands to the list, and they will be executed every single time this add-on starts. +### Option: `disable_telemetry` + +Disables annonymous usage telemetry data from being sent to code-server. + ### Option: `leave_front_door_open` Adding this option to the add-on configuration allows you to disable diff --git a/vscode/config.json b/vscode/config.json index 6fc954a..713926b 100755 --- a/vscode/config.json +++ b/vscode/config.json @@ -36,7 +36,8 @@ "certfile": "fullchain.pem", "keyfile": "privkey.pem", "packages": [], - "init_commands": [] + "init_commands": [], + "disable_telemetry": false }, "schema": { "log_level": "match(^(trace|debug|info|notice|warning|error|fatal)$)?", @@ -45,6 +46,7 @@ "keyfile": "str", "packages": ["str"], "init_commands": ["str"], + "disable_telemetry": "bool?", "leave_front_door_open": "bool?" } } diff --git a/vscode/rootfs/etc/services.d/code/run b/vscode/rootfs/etc/services.d/code/run index d7f46b1..916cedd 100644 --- a/vscode/rootfs/etc/services.d/code/run +++ b/vscode/rootfs/etc/services.d/code/run @@ -12,7 +12,10 @@ options+=(--user-data-dir "/data/vscode") options+=(--extensions-dir "/data/vscode/extensions") options+=(--host 127.0.0.1) options+=(--allow-http) -options+=(--disable-telemetry) + +if bashio::config.true 'disable_telemetry'; then + options+=(--disable-telemetry) +fi # Disable code authentication, we use HA authentication options+=(--no-auth)