supbuddy 3.0.8 → 3.0.10
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/daemon/worker.cjs +13 -6
- package/package.json +1 -1
package/dist/daemon/worker.cjs
CHANGED
|
@@ -37777,6 +37777,12 @@ function projectsNeedingVmMigration(projects) {
|
|
|
37777
37777
|
return projects.filter((p) => p.isolation === "vm");
|
|
37778
37778
|
}
|
|
37779
37779
|
const ALL_SCOPE_KEYS = Object.keys(McpScopesSchema.shape);
|
|
37780
|
+
function dnsResolverRepairNeeded(resolver) {
|
|
37781
|
+
if (resolver.in_sync !== false) return false;
|
|
37782
|
+
const hasMissing = Array.isArray(resolver.missing) && resolver.missing.length > 0;
|
|
37783
|
+
const hasExtra = Array.isArray(resolver.extra) && resolver.extra.length > 0;
|
|
37784
|
+
return hasMissing || hasExtra;
|
|
37785
|
+
}
|
|
37780
37786
|
const readTools = {
|
|
37781
37787
|
list_pending_vm_migrations: async () => {
|
|
37782
37788
|
const projects = useStore.getState().projects;
|
|
@@ -37829,19 +37835,19 @@ const readTools = {
|
|
|
37829
37835
|
error: e.message
|
|
37830
37836
|
})) : Promise.resolve({ ok: false, resolved: [], reachable: [], error: `caddy not alive (status=${proxyStatus})` })
|
|
37831
37837
|
]);
|
|
37832
|
-
const
|
|
37838
|
+
const resolverRepairNeeded = dnsResolverRepairNeeded(resolver);
|
|
37833
37839
|
return {
|
|
37834
37840
|
worker: { running: true, uptime_ms: process.uptime() * 1e3 },
|
|
37835
37841
|
mcp_server: s.mcpServerState,
|
|
37836
37842
|
proxy: {
|
|
37837
37843
|
...s.proxyState,
|
|
37838
|
-
needsPrivilegedRepair: s.proxyState.needsPrivilegedRepair ||
|
|
37844
|
+
needsPrivilegedRepair: s.proxyState.needsPrivilegedRepair || resolverRepairNeeded,
|
|
37839
37845
|
status: proxyStatus,
|
|
37840
37846
|
liveness
|
|
37841
37847
|
},
|
|
37842
37848
|
dns: {
|
|
37843
37849
|
server: { ...s.dnsState, probe },
|
|
37844
|
-
resolver: { ...resolver, repairNeeded:
|
|
37850
|
+
resolver: { ...resolver, repairNeeded: resolverRepairNeeded },
|
|
37845
37851
|
reachability
|
|
37846
37852
|
}
|
|
37847
37853
|
};
|
|
@@ -41549,6 +41555,7 @@ const executors = {
|
|
|
41549
41555
|
const m = useStore.getState().mappings.find((x) => x.id === args.id_or_domain || x.domain === args.id_or_domain);
|
|
41550
41556
|
if (!m) throw new McpError("plan_not_found", `Mapping not found`);
|
|
41551
41557
|
const trashed = await trashMapping(m.id, `mcp:${ctx.client_id}`);
|
|
41558
|
+
await applyMappingChangeSideEffects();
|
|
41552
41559
|
return { trashed_id: trashed.id };
|
|
41553
41560
|
},
|
|
41554
41561
|
cloud_teardown: async (args) => daemonCloudTeardownProject(args.project_id),
|
|
@@ -48243,7 +48250,7 @@ port ${port}
|
|
|
48243
48250
|
commands.push(`cp "${tmpPath}" "${filePath}"`);
|
|
48244
48251
|
}
|
|
48245
48252
|
const writeChain = commands.join(" && ");
|
|
48246
|
-
const flush = "{ dscacheutil -flushcache; killall -HUP mDNSResponder 2>/dev/null; true; }";
|
|
48253
|
+
const flush = "{ dscacheutil -flushcache; launchctl kickstart -k system/com.apple.mDNSResponder.reloaded 2>/dev/null || launchctl kickstart -k system/com.apple.mDNSResponder 2>/dev/null || killall -HUP mDNSResponder 2>/dev/null; true; }";
|
|
48247
48254
|
return { command: `${writeChain} && ${flush}`, tmpFiles };
|
|
48248
48255
|
}
|
|
48249
48256
|
async function buildMacOsCleanupCommand() {
|
|
@@ -50012,7 +50019,7 @@ async function checkProxyReachabilityAndSurface() {
|
|
|
50012
50019
|
const hintMessage = {
|
|
50013
50020
|
mdns_hijack: `Browser DNS for ${result.domain} returns ${result.resolved.join(", ")} (your own LAN IP) but Caddy isn't reachable on port ${result.port}. This usually means LAN sharing is publishing the name via Bonjour and pf rules need a re-apply — toggle the proxy off/on, or disable LAN sharing.`,
|
|
50014
50021
|
foreign_owner: `Another device on your LAN is responding for ${result.domain} (${result.resolved.join(", ")}) — Bonjour/mDNS race for the .local namespace. Switch this project's TLD to .test in Settings, or take the other device offline.`,
|
|
50015
|
-
no_resolution: `The OS resolver couldn't resolve ${result.domain}.
|
|
50022
|
+
no_resolution: `The OS resolver couldn't resolve ${result.domain}. The resolver files and DNS server on :${store2.dnsState.port} may be fine — on macOS Sonoma+ the OS often just hasn't loaded /etc/resolver yet. Click RETRY (or restart the proxy) to rewrite the resolver files and reload the OS DNS cache. If it persists, run get_health → dns.resolver to check for missing files.`,
|
|
50016
50023
|
resolved_but_unreachable: `${result.domain} resolves to ${result.resolved.join(", ")} but TCP connect to port ${result.port} fails. Likely a port-forwarding rule is missing for that IP — toggle the proxy off/on.`
|
|
50017
50024
|
};
|
|
50018
50025
|
const effectiveHint = resolveReachabilityHint2(result.hint, store2.settings.lanSharing);
|
|
@@ -51161,7 +51168,7 @@ process.on("message", async (message) => {
|
|
|
51161
51168
|
store2.deleteMapping(id);
|
|
51162
51169
|
process.send({ type: "mappings:delete:response", data: { success: true } });
|
|
51163
51170
|
if (isCaddyRunning()) {
|
|
51164
|
-
reloadCaddyConfig().catch((err) => console.error("[Worker]
|
|
51171
|
+
reloadCaddyConfig().then(() => reapplyDnsResolversIfDrifted("mappings:delete")).catch((err) => console.error("[Worker] Caddy reload / DNS re-apply after mapping delete failed:", err));
|
|
51165
51172
|
}
|
|
51166
51173
|
break;
|
|
51167
51174
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "supbuddy",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.10",
|
|
4
4
|
"description": "Run multiple Supabase projects at once on custom local domains with HTTPS. A headless CLI and daemon (proxy, DNS, Supabase/Compose lifecycle, MCP) for macOS and Linux.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"supabase",
|