Skip to content
This repository was archived by the owner on Feb 3, 2025. It is now read-only.

Commit cfc40f3

Browse files
Merge pull request #109 from aeternity/v0.8.1-rc2
V0.8.1 rc2
2 parents b5a11fc + 55e44a3 commit cfc40f3

3 files changed

Lines changed: 14 additions & 3 deletions

File tree

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "aepp-middleware"
3-
version = "0.8.0"
3+
version = "0.8.1"
44
authors = ["John Newby <@johnsnewby>", "Shubhendu Shekhar <@shekhar-shubhendu>", "Andrea Giacobino <@noandrea>" ]
55

66
[features]

src/main.rs

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,6 +212,14 @@ fn main() {
212212
.help("Load specific heights, values separated by comma, ranges with from-to accepted")
213213
.takes_value(true),
214214
)
215+
.arg(
216+
Arg::with_name("websocket")
217+
.short("w")
218+
.long("websocket")
219+
.help("Activate websocket (only valid when -p (populate) option also set")
220+
.requires("populate")
221+
.takes_value(false),
222+
)
215223
.get_matches();
216224

217225
let url = env::var("NODE_URL")
@@ -223,6 +231,7 @@ fn main() {
223231
let verify = matches.is_present("verify");
224232
let heights = matches.is_present("heights");
225233
let daemonize = matches.is_present("daemonize");
234+
let websocket = matches.is_present("websocket");
226235

227236
if daemonize {
228237
let daemonize = Daemonize::new();
@@ -294,6 +303,9 @@ fn main() {
294303
populate_thread = Some(thread::spawn(move || {
295304
loader.start();
296305
}));
306+
if websocket {
307+
websocket::start_ws();
308+
}
297309
}
298310

299311
if serve {
@@ -302,7 +314,6 @@ fn main() {
302314
dest_url: url.to_string(),
303315
port: 3013,
304316
};
305-
websocket::start_ws(); //start the websocket server
306317
ms.start();
307318
loop {
308319
// just to stop main() thread exiting.

0 commit comments

Comments
 (0)