#!/usr/bin/env bash set -euo pipefail node --input-type=module <<'NODE' import fs from 'node:fs'; const readJson = (path) => JSON.parse(fs.readFileSync(path, 'utf8')); const checks = { packageVersion: readJson('/app/package.json').version, interfacesVersion: readJson('/app/node_modules/@serve.zone/interfaces/package.json').version, apiVersion: readJson('/app/node_modules/@serve.zone/api/package.json').version, hasDistServe: fs.existsSync('/app/dist_serve/index.html'), }; await import('/app/dist_ts/index.js'); if (checks.packageVersion !== '5.3.0') { throw new Error(`Unexpected Cloudly package version ${checks.packageVersion}`); } if (checks.interfacesVersion !== '5.4.6') { throw new Error(`Unexpected interfaces version ${checks.interfacesVersion}`); } if (checks.apiVersion !== '5.3.4') { throw new Error(`Unexpected api version ${checks.apiVersion}`); } if (!checks.hasDistServe) { throw new Error('Missing dist_serve/index.html'); } console.log(JSON.stringify(checks)); NODE