Public release release-ea887c8f56cd
Source commit: ea887c8f56cd53985a1179b13e5f1b85c485f584 Public tree identity: sha256:b96a97aacdbc8fd4fc2ea20d0e1450280d46db3f24aabe1475e5fbe20e05f255
This commit is contained in:
parent
9223c54939
commit
2a0f7ded04
37 changed files with 3145 additions and 628 deletions
|
|
@ -190,8 +190,8 @@ function nodeSignatureMessage(
|
|||
);
|
||||
}
|
||||
|
||||
function signedNodeHeartbeat(node, identity) {
|
||||
const request = { type: "node_heartbeat", node };
|
||||
function signedNodeHeartbeat(tenant, project, node, identity) {
|
||||
const request = { type: "node_heartbeat", tenant, project, node };
|
||||
const nonce = `self-hosted-heartbeat-${process.pid}-${Date.now()}`;
|
||||
const issuedAt = Math.floor(Date.now() / 1000);
|
||||
const signature = crypto.sign(
|
||||
|
|
@ -313,8 +313,10 @@ async function attachTrustedNode(addr, node, capabilities = linuxNodeCapabilitie
|
|||
|
||||
const heartbeat = await send(addr, {
|
||||
type: "node_heartbeat",
|
||||
tenant: "team",
|
||||
project: "self-hosted",
|
||||
node,
|
||||
node_signature: signedNodeHeartbeat(node, identity)
|
||||
node_signature: signedNodeHeartbeat("team", "self-hosted", node, identity)
|
||||
});
|
||||
assert.strictEqual(heartbeat.type, "node_heartbeat");
|
||||
|
||||
|
|
@ -569,6 +571,8 @@ async function attachTrustedNode(addr, node, capabilities = linuxNodeCapabilitie
|
|||
|
||||
const reconnected = await send(addr, signedNodeRequest("team-linux-a", teamLinuxA, "reconnect_node", {
|
||||
type: "reconnect_node",
|
||||
tenant: "team",
|
||||
project: "self-hosted",
|
||||
node: "team-linux-a",
|
||||
process: "vp-team-build",
|
||||
epoch: started.epoch
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue