From 043aedfde4648726d316a20081e5d24332effc1d Mon Sep 17 00:00:00 2001 From: naimo84 Date: Tue, 8 Feb 2022 09:57:31 +0100 Subject: [PATCH 1/2] feat: add raft storage join --- features.md | 5 +++++ src/commands.js | 4 ++++ 2 files changed, 9 insertions(+) diff --git a/features.md b/features.md index ef210019..7c210751 100644 --- a/features.md +++ b/features.md @@ -72,6 +72,11 @@ `GET /{{databasePath}}/creds/{{name}}` +## vault.raftJoin + +`POST /sys/storage/raft/join` + + ## vault.unmount `DELETE /sys/mounts/{{mount_point}}` diff --git a/src/commands.js b/src/commands.js index 98ea6efa..2229e039 100644 --- a/src/commands.js +++ b/src/commands.js @@ -300,6 +300,10 @@ module.exports = { method: 'GET', path: '/{{databasePath}}/creds/{{name}}', }, + raftJoin:{ + method: 'POST', + path: '/sys/storage/raft/join' + }, unmount: { method: 'DELETE', path: '/sys/mounts/{{mount_point}}', From 0096d94340ad29ed470475d7f056752f957ddec8 Mon Sep 17 00:00:00 2001 From: naimo84 Date: Tue, 8 Feb 2022 09:58:48 +0100 Subject: [PATCH 2/2] feat: add recovery options to init, remove required secret options --- package.json | 1 + src/commands.js | 11 +++++++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/package.json b/package.json index 2053c824..db6990a5 100644 --- a/package.json +++ b/package.json @@ -60,6 +60,7 @@ "contributors": [ "Adam Kelsall (https://github.com/adamkelsall)", "Alex Early (https://github.com/aearly)", + "Benjamin Neumann (https://github.com/naimo84)", "Brandon Ros (https://github.com/brandonros)", "Charles Phillips (https://github.com/doublerebel)", "David Drewery (https://github.com/EXPEddrewery)", diff --git a/src/commands.js b/src/commands.js index 2229e039..d3f15060 100644 --- a/src/commands.js +++ b/src/commands.js @@ -101,6 +101,14 @@ module.exports = { type: 'integer', minimum: 1, }, + recovery_shares: { + type: 'integer', + minimum: 1, + }, + recovery_threshold: { + type: 'integer', + minimum: 1, + }, pgp_keys: { type: 'array', items: { @@ -108,8 +116,7 @@ module.exports = { }, uniqueItems: true, }, - }, - required: ['secret_shares', 'secret_threshold'], + }, }, res: { type: 'object',