From 54e80bf7153dc596cf8d2af9068d2e71524d54e7 Mon Sep 17 00:00:00 2001 From: sashimono Date: Thu, 20 Aug 2026 05:01:00 +0200 Subject: [PATCH 1/3] Update command-handler.js --- lib/command-handler.js | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/command-handler.js b/lib/command-handler.js index 23a6243..0449784 100644 --- a/lib/command-handler.js +++ b/lib/command-handler.js @@ -243,7 +243,8 @@ async function acquire(host, options) { userKeys.publicKey, options.contractId, options.image, - appenv.hpInitCfg || {}); + appenv.hpInitCfg || {}), + { sendMax: options.sendmax }); success('Instance created!', result); } catch (e) { @@ -1143,4 +1144,4 @@ module.exports = { extend, extendInstance, audit -}; \ No newline at end of file +}; From f2e5d5f47803c1b3b38d3527d42286fb7c1c8041 Mon Sep 17 00:00:00 2001 From: sashimono Date: Thu, 20 Aug 2026 05:01:58 +0200 Subject: [PATCH 2/3] Update evernode-manager.js --- lib/evernode-manager.js | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/lib/evernode-manager.js b/lib/evernode-manager.js index 215f4c8..9eeb120 100644 --- a/lib/evernode-manager.js +++ b/lib/evernode-manager.js @@ -115,7 +115,15 @@ class EvernodeManager { config: config }; - const result = await this.#tenantClient.acquireLease(hostAddress, requirement, { leaseOfferIndex: options.leaseIndex, transactionOptions: { sequence: options.tenantSequence } }); + const acquireOptions = { + leaseOfferIndex: options.leaseIndex, + transactionOptions: { sequence: options.tenantSequence } + }; + + if (options.sendMax !== undefined && options.sendMax !== null) + acquireOptions.sendMax = options.sendMax; + + const result = await this.#tenantClient.acquireLease(hostAddress, requirement, acquireOptions); const acquiredTimestamp = Date.now(); const instanceName = result.instance.name; From c9b706990b8e09ed8df07950ecee32720e5c0aa2 Mon Sep 17 00:00:00 2001 From: sashimono Date: Thu, 20 Aug 2026 05:10:29 +0200 Subject: [PATCH 3/3] Update index.js --- index.js | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/index.js b/index.js index c9c737e..ad29ab9 100755 --- a/index.js +++ b/index.js @@ -55,6 +55,7 @@ program .option('-m, --moments [moments]', 'Life moments') .option('-c, --contract-id [contract-id]', 'Contract id') .option('-i, --image [image]', 'Instance image') + .option('-s, --sendmax [evr]', 'Maximum EVR allowed for acquiring the instance') .action(acquire); program @@ -97,6 +98,7 @@ program .option('-m, --moments [moments]', 'Life moments') .option('-c, --contract-id [contract-id]', 'Contract id') .option('-i, --image [image]', 'Instance image') + .option('-s, --sendmax [evr]', 'Maximum EVR allowed for acquiring the instance') .action(acquireAndDeploy); program @@ -164,4 +166,4 @@ catch (e) { // Log the exception if not a console output. if (!('stdout' in e) && !('stderr' in e)) console.error(e); -} \ No newline at end of file +}