aboutsummaryrefslogtreecommitdiffstats
path: root/packaging/win
diff options
context:
space:
mode:
authorChristophe Besson <cbesson@gmail.com>2026-09-26 12:23:16 +0200
committerChristophe Besson <cbesson@gmail.com>2026-09-26 12:23:16 +0200
commitfc761e7df40eac828d4e9858fab56958078c928b (patch)
treefc62061f70f374fcc8366d7ef15882a2d983ac9b /packaging/win
parent1c07ae23f3694b972e307c50c9c09f1c429f2ea2 (diff)
downloadmeshbay-fc761e7df40eac828d4e9858fab56958078c928b.tar.gz
fix(node): read the packaged TMDB token in place
A node onboarded by the desktop client never ran `init`, so default.env was never copied to node.env; and default.env was 0600 root, unreadable to a per-user node anyway. The daemon now loads it beneath node.env, 0644. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Diffstat (limited to 'packaging/win')
-rw-r--r--packaging/win/build-node-runtime.ps18
1 files changed, 4 insertions, 4 deletions
diff --git a/packaging/win/build-node-runtime.ps1 b/packaging/win/build-node-runtime.ps1
index 20eacc8..28c4061 100644
--- a/packaging/win/build-node-runtime.ps1
+++ b/packaging/win/build-node-runtime.ps1
@@ -120,9 +120,9 @@ else {
# --- 5. default.env (shared TMDB token) ------------------------------
# Beside the exe, where platform.packaged_default_env() looks for it, and the
-# same placement ffmpeg gets above. `meshbay-node init` copies it to
-# %LOCALAPPDATA%\meshbay\node.env, and the daemon loads that file itself:
-# Windows autostart is a Startup-folder .vbs, with no systemd EnvironmentFile.
+# same placement ffmpeg gets above. The daemon reads it in place, beneath
+# %LOCALAPPDATA%\meshbay\node.env: Windows autostart is a Startup-folder .vbs,
+# with no systemd EnvironmentFile.
function Get-TmdbToken([string]$File) {
if (-not $File -or -not (Test-Path -LiteralPath $File)) { return "" }
$lines = Get-Content -LiteralPath $File
@@ -149,7 +149,7 @@ $noBom = New-Object System.Text.UTF8Encoding $false # a BOM would break parsin
if ($tmdb) {
$body = @(
"# Default environment for meshbay-node.",
- "# Copied to <config>\node.env by 'meshbay-node init' if it does not exist.",
+ "# Read by the daemon beneath <config>\node.env; set a value there to override it.",
"",
"# TMDB API token for the Videos app (read-only, shared across installations)",
"MESHBAY_TMDB_DEFAULT_TOKEN=$tmdb"