From 93cdf1f2f191b6118ba0db63449427567ec05a23 Mon Sep 17 00:00:00 2001 From: Your Name Date: Mon, 29 Sep 2025 21:26:21 -0600 Subject: [PATCH] Remove OTT log highlighter --- CloudronManifest.json | 2 +- start.sh | 39 +++------------------------------------ 2 files changed, 4 insertions(+), 37 deletions(-) diff --git a/CloudronManifest.json b/CloudronManifest.json index 134ebe7..0f720c0 100644 --- a/CloudronManifest.json +++ b/CloudronManifest.json @@ -7,7 +7,7 @@ "contactEmail": "contact@ente.io", "tagline": "Open Source End-to-End Encrypted Photos & Authentication", "upstreamVersion": "1.0.0", - "version": "0.1.121", + "version": "0.1.122", "healthCheckPath": "/ping", "httpPort": 3080, "memoryLimit": 1073741824, diff --git a/start.sh b/start.sh index aa35343..73b92e6 100644 --- a/start.sh +++ b/start.sh @@ -463,34 +463,6 @@ for webapp in photos accounts auth cast; do fi done -# =============================================== -# Museum log highlighter (extract OTTs from logs) -# =============================================== -prepare_ott_highlighter() { - cat > "/app/data/ente/server/ott-log-highlight.js" << 'EOF' -const readline = require('readline'); -const rl = readline.createInterface({ input: process.stdin }); - -const shouldHighlight = (line) => { - if (!line) return false; - const lower = line.toLowerCase(); - if (lower.includes('added ott')) return true; - if (lower.includes('ott"') || lower.includes(' ott ')) return true; - return false; -}; - -rl.on('line', (line) => { - process.stdout.write(line + '\n'); - if (shouldHighlight(line)) { - const trimmed = line.trim(); - process.stdout.write('============================================================\n'); - process.stdout.write(`HIGHLIGHT: ${trimmed}\n`); - process.stdout.write('============================================================\n'); - } -}); -EOF -} - # =============================================== # Node.js Placeholder Server # =============================================== @@ -632,9 +604,7 @@ const apiHandlers = { } const responsePayload = buildResponse(email); - log('============================================================'); - log(`HIGHLIGHT: Verifying OTT ${ott} for ${email}`); - log('============================================================'); + log(`Verifying OTT ${ott} for ${email}`); res.writeHead(200, { 'Content-Type': 'application/json' }); res.end(JSON.stringify(responsePayload)); @@ -721,9 +691,7 @@ const apiHandlers = { } const ott = ('' + Math.floor(100000 + Math.random() * 900000)).slice(-6); - log('============================================================'); - log(`HIGHLIGHT: Generated OTT ${ott} for ${email}`); - log('============================================================'); + log(`Generated OTT ${ott} for ${email}`); res.writeHead(200, { 'Content-Type': 'application/json' }); res.end(JSON.stringify({ success: true, ott, email })); @@ -895,10 +863,9 @@ if [ "$USE_PLACEHOLDER" = true ]; then create_nodejs_placeholder else log "INFO" "Starting actual Museum server" - prepare_ott_highlighter cd /app/data/ente/server export ENVIRONMENT="${MUSEUM_ENVIRONMENT:-local}" - stdbuf -oL "$MUSEUM_BIN" 2>&1 | node ott-log-highlight.js | tee -a "$MUSEUM_LOG" & + stdbuf -oL "$MUSEUM_BIN" 2>&1 | tee -a "$MUSEUM_LOG" & MUSEUM_PID=$! log "INFO" "Started Museum server (pipeline PID: $MUSEUM_PID)"