fix(cms): keep version tag fresh — deploy restarts CMS, editor page no-store
CI Pipeline with Test Management / 🧪 Run Tests & Generate Reports (push) Waiting to run
CI Pipeline with Test Management / 🐳 Docker Integration Tests (push) Blocked by required conditions
CI Pipeline with Test Management / 🏗️ Build Docker Image (push) Blocked by required conditions
CI Pipeline with Test Management / 📊 Generate Test Summary (push) Blocked by required conditions
Test Reporting & Gherkin Analysis / 🧪 Run Tests & Generate Reports (push) Waiting to run
Test Reporting & Gherkin Analysis / 📊 Analyze Test Coverage (push) Blocked by required conditions
Test Reporting & Gherkin Analysis / 🔄 Sync with Linear (push) Blocked by required conditions
Test Reporting & Gherkin Analysis / ⚡ Performance Monitoring (push) Blocked by required conditions

The version tag is the git SHA read at CMS startup, but the deploy script
only rebuilt the website container, leaving the tag stale (v8838304 shown
after aa8d926 was live). The local deploy script now restarts the CMS
service after the server-side deploy (the CMS publish flow is unaffected —
it calls deploy.sh directly and never restarts itself). The editor main
page also gains Cache-Control: no-store so browsers stop caching it.

Closes MITHOME-71
This commit is contained in:
Do Siki
2026-08-19 14:38:40 +02:00
parent aa8d92646c
commit 14a72a3ffe
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -347,7 +347,7 @@ const server = http.createServer(async (req, res) => {
// overwrite those changes.
const contentHash = crypto.createHash('sha256').update(jsonData).digest('hex');
res.writeHead(200, { 'Content-Type': 'text/html; charset=utf-8' });
res.writeHead(200, { 'Content-Type': 'text/html; charset=utf-8', 'Cache-Control': 'no-store' });
res.end(HTML(activeFile, jsonData, message, CSRF_TOKEN, FILE_LABELS, clientJs, contentHash, DEPLOY_VERSION));
});
+1 -1
View File
@@ -46,7 +46,7 @@ git push origin "${DEPLOY_BRANCH}"
printf '3/4 Staging deploy (%s:%s)…\n' "${STAGE_HOST}" "${STAGE_PATH}"
ssh -o BatchMode=yes -o ConnectTimeout=15 "${STAGE_HOST}" \
"cd '${STAGE_PATH}' && git pull --ff-only origin '${DEPLOY_BRANCH}' && ./deploy.sh staging"
"cd '${STAGE_PATH}' && git pull --ff-only origin '${DEPLOY_BRANCH}' && ./deploy.sh staging && sudo systemctl restart mozdit-content-editor.service"
printf '4/4 Staging smoke teszt (%s)…\n' "${STAGE_URL}"
(