@neat.is/core 0.10.6-dev.20261010 → 0.10.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-H2BAPN33.js → chunk-MW2XYLCS.js} +384 -181
- package/dist/chunk-MW2XYLCS.js.map +1 -0
- package/dist/{chunk-52SCEPEW.js → chunk-OKM4N7GH.js} +12 -4
- package/dist/{chunk-52SCEPEW.js.map → chunk-OKM4N7GH.js.map} +1 -1
- package/dist/cli.cjs +699 -540
- package/dist/cli.cjs.map +1 -1
- package/dist/cli.js +2 -2
- package/dist/index.cjs +732 -520
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +6 -0
- package/dist/index.d.ts +6 -0
- package/dist/index.js +2 -2
- package/dist/neatd.cjs +732 -520
- package/dist/neatd.cjs.map +1 -1
- package/dist/neatd.js +2 -2
- package/dist/server.cjs +721 -570
- package/dist/server.cjs.map +1 -1
- package/dist/server.js +1 -1
- package/package.json +2 -2
- package/dist/chunk-H2BAPN33.js.map +0 -1
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
startConnectorPolling,
|
|
29
29
|
startPersistLoop,
|
|
30
30
|
startStalenessLoop
|
|
31
|
-
} from "./chunk-
|
|
31
|
+
} from "./chunk-MW2XYLCS.js";
|
|
32
32
|
import {
|
|
33
33
|
listProjects,
|
|
34
34
|
pruneRegistry,
|
|
@@ -534,6 +534,15 @@ async function fetchPodLog(transport, namespace, podName, opts = {}) {
|
|
|
534
534
|
return void 0;
|
|
535
535
|
}
|
|
536
536
|
}
|
|
537
|
+
function hasLogContent(text) {
|
|
538
|
+
return typeof text === "string" && text.trim().length > 0;
|
|
539
|
+
}
|
|
540
|
+
async function fetchPodProcessLog(transport, namespace, podName, opts = {}) {
|
|
541
|
+
const previous = await fetchPodLog(transport, namespace, podName, { ...opts, previous: true });
|
|
542
|
+
if (hasLogContent(previous)) return previous;
|
|
543
|
+
const current = await fetchPodLog(transport, namespace, podName, { ...opts, previous: false });
|
|
544
|
+
return hasLogContent(current) ? current : void 0;
|
|
545
|
+
}
|
|
537
546
|
|
|
538
547
|
// src/connectors/kubernetes/kubeconfig.ts
|
|
539
548
|
import { readFileSync } from "fs";
|
|
@@ -1072,11 +1081,10 @@ var KubernetesConnector = class {
|
|
|
1072
1081
|
const targets = faultedPods(deployments, pods, this.config);
|
|
1073
1082
|
await Promise.all(
|
|
1074
1083
|
targets.map(async (t) => {
|
|
1075
|
-
const text = await
|
|
1084
|
+
const text = await fetchPodProcessLog(transport, namespace, t.podName, {
|
|
1076
1085
|
...t.container ? { container: t.container } : {},
|
|
1077
1086
|
tailLines: PROCESS_LOG_TAIL_LINES,
|
|
1078
1087
|
limitBytes: PROCESS_LOG_LIMIT_BYTES,
|
|
1079
|
-
previous: true,
|
|
1080
1088
|
...opts
|
|
1081
1089
|
});
|
|
1082
1090
|
if (typeof text === "string" && text.length > 0) logs.set(podLogKey(t.podName, t.container), text);
|
|
@@ -2012,4 +2020,4 @@ export {
|
|
|
2012
2020
|
resolveHost,
|
|
2013
2021
|
startDaemon
|
|
2014
2022
|
};
|
|
2015
|
-
//# sourceMappingURL=chunk-
|
|
2023
|
+
//# sourceMappingURL=chunk-OKM4N7GH.js.map
|