fix: bind bootstrap setup codes to node profile

This commit is contained in:
Peter Steinberger
2026-03-22 23:55:10 -07:00
parent 4580d585ff
commit a600c72ed7
8 changed files with 117 additions and 9 deletions

View File

@@ -22,6 +22,9 @@ export type PairingSetupPayload = {
bootstrapToken: string;
};
const PAIRING_SETUP_BOOTSTRAP_ROLES = ["node"] as const;
const PAIRING_SETUP_BOOTSTRAP_SCOPES: string[] = [];
export type PairingSetupCommandResult = {
code: number | null;
stdout: string;
@@ -384,6 +387,8 @@ export async function resolvePairingSetupFromConfig(
bootstrapToken: (
await issueDeviceBootstrapToken({
baseDir: options.pairingBaseDir,
roles: PAIRING_SETUP_BOOTSTRAP_ROLES,
scopes: PAIRING_SETUP_BOOTSTRAP_SCOPES,
})
).token,
},