Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Commit

Permalink
Add -skip-signature option to launcher
Browse files Browse the repository at this point in the history
  • Loading branch information
heifner committed Sep 5, 2017
1 parent 8422033 commit a54725d
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions programs/launcher/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,7 @@ struct launcher_def {
string shape;
bf::path genesis;
bf::path output;
bool skip_transaction_signatures = false;
testnet_def network;
string data_dir_base;
string alias_base;
Expand Down Expand Up @@ -234,7 +235,8 @@ launcher_def::set_options (bpo::options_description &cli) {
("pnodes,p",bpo::value<int>()->default_value(1),"number of nodes that are producers")
("shape,s",bpo::value<string>()->default_value("ring"),"network topology, use \"ring\" \"star\" \"mesh\" or give a filename for custom")
("genesis,g",bpo::value<bf::path>()->default_value("./genesis.json"),"set the path to genesis.json")
("output,o",bpo::value<bf::path>(),"save a copy of the generated topology in this file");
("output,o",bpo::value<bf::path>(),"save a copy of the generated topology in this file")
("skip-signature,s", bpo::value<bool>(), "EOSD does not require transaction signatures.");
}

void
Expand All @@ -249,6 +251,8 @@ launcher_def::initialize (const variables_map &vmap) {
genesis = vmap["genesis"].as<bf::path>();
if (vmap.count("output"))
output = vmap["output"].as<bf::path>();
if (vmap.count("skip-signature"))
skip_transaction_signatures = true;

producers = 21;
data_dir_base = "tn_data_";
Expand Down Expand Up @@ -544,7 +548,11 @@ launcher_def::launch (eosd_def &node, string &gts) {
node_rt_info info;
info.remote = node.remote;

string eosdcmd = "programs/eosd/eosd --skip-transaction-signatures --data-dir " + node.data_dir;
string eosdcmd = "programs/eosd/eosd ";
if (skip_transaction_signatures) {
eosdcmd += "--skip-transaction-signatures ";
}
eosdcmd += "--data-dir " + node.data_dir;
if (gts.length()) {
eosdcmd += " --genesis-timestamp " + gts;
}
Expand Down

0 comments on commit a54725d

Please sign in to comment.