From 30c88b1e50da14ea48c8b2a9976ca7a7c8b96338 Mon Sep 17 00:00:00 2001 From: thelittlefireman <5165783+thelittlefireman@users.noreply.github.com> Date: Sun, 2 Nov 2025 15:09:20 +0000 Subject: [PATCH 1/2] Add new env var --- README.md | 1 + app/Dockerfile | 2 ++ docker-compose.yml | 1 + 3 files changed, 4 insertions(+) diff --git a/README.md b/README.md index 0d89066..4e113ee 100644 --- a/README.md +++ b/README.md @@ -119,6 +119,7 @@ The web app is automatically configured to connect to your self-hosted services - `NN_AUTH_HOST` - Override the default authentication server URL (defaults to `AUTH_SERVER_PUBLIC_URL`) - `NN_SSE_HOST` - Override the default SSE server URL (defaults to `SSE_SERVER_PUBLIC_URL`) - `NN_MONOGRAPH_HOST` - Override the default monograph server URL (defaults to `MONOGRAPH_PUBLIC_URL`) +- `NN_NOTESNOOK_HOST` - Override the default monograph server URL (defaults to `NOTESNOOK_APP_PUBLIC_URL`) **Note**: These variables are optional and will automatically use your self-hosted service URLs if not specified. diff --git a/app/Dockerfile b/app/Dockerfile index 47fdade..1a549bc 100644 --- a/app/Dockerfile +++ b/app/Dockerfile @@ -18,12 +18,14 @@ ARG NN_API_HOST ARG NN_AUTH_HOST ARG NN_SSE_HOST ARG NN_MONOGRAPH_HOST +ARG NN_NOTESNOOK_HOST # Set environment variables for the build process ENV NN_API_HOST=${NN_API_HOST} ENV NN_AUTH_HOST=${NN_AUTH_HOST} ENV NN_SSE_HOST=${NN_SSE_HOST} ENV NN_MONOGRAPH_HOST=${NN_MONOGRAPH_HOST} +ENV NN_NOTESNOOK_HOST=${NN_NOTESNOOK_HOST} # Build just the web app RUN npm run build:web diff --git a/docker-compose.yml b/docker-compose.yml index 6086b2f..84787dc 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -217,6 +217,7 @@ services: NN_AUTH_HOST: ${AUTH_SERVER_PUBLIC_URL} NN_SSE_HOST: ${SSE_SERVER_PUBLIC_URL} NN_MONOGRAPH_HOST: ${MONOGRAPH_PUBLIC_URL} + NN_NOTESNOOK_HOST: ${NOTESNOOK_APP_PUBLIC_URL} ports: - "8888:80" restart: always From e327dc5e7d7c3140147e452c58020ebc30c1c83f Mon Sep 17 00:00:00 2001 From: thelittlefireman <5165783+thelittlefireman@users.noreply.github.com> Date: Sun, 2 Nov 2025 15:23:54 +0000 Subject: [PATCH 2/2] Change npm install, upgrade to node 22 --- app/Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/Dockerfile b/app/Dockerfile index 1a549bc..b2856a2 100644 --- a/app/Dockerfile +++ b/app/Dockerfile @@ -1,5 +1,5 @@ # Build Stage -FROM node:20 AS builder +FROM node:22 AS builder WORKDIR /app @@ -11,7 +11,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends git \ RUN git clone --depth=1 https://github.com/beardedtek/notesnook.git . # Install dependencies (monorepo root) -RUN npm ci +RUN npm ci --ignore-scripts --prefer-offline --no-audit && npm run bootstrap -- --scope=web # Accept build-time environment variables for server URLs ARG NN_API_HOST