fix: proxmox guest sync, startup snippet sync, drop dead cloudflare ssh transport

This commit is contained in:
LukeGus committed 2026-09-28 21:59:37 -05:00
1 parent 44062e30d1
commit ffa872ebd3
19 files changed
+270 -292

No files matched your search

@@ -0,0 +1,53 @@
import { describe, expect, it } from "vitest";
import { getJumpHostSocks5Config } from "../../hosts/jump-host-proxy.js";
describe("getJumpHostSocks5Config", () => {
it("uses the first jump host proxy settings", () => {
expect(
getJumpHostSocks5Config({
useSocks5: true,
socks5Host: "proxy.internal",
socks5Port: 1080,
socks5Username: "user",
socks5Password: "secret",
}),
).toEqual({
useSocks5: true,
socks5Host: "proxy.internal",
socks5Port: 1080,
socks5Username: "user",
socks5Password: "secret",
socks5ProxyChain: [],
});
});
it("does not use destination proxy settings for the first jump host", () => {
expect(getJumpHostSocks5Config({ useSocks5: false })).toBeNull();
});
it("accepts a serialized proxy chain from the first jump host", () => {
const chain = [
{
id: "proxy-1",
name: "Proxy 1",
host: "proxy.internal",
port: 1080,
type: "socks5" as const,
},
];
expect(
getJumpHostSocks5Config({
useSocks5: true,
socks5ProxyChain: JSON.stringify(chain),
}),
).toEqual({
useSocks5: true,
socks5Host: undefined,
socks5Port: undefined,
socks5Username: undefined,
socks5Password: undefined,
socks5ProxyChain: chain,
});
});
});