module Daemon
Defined in:
daemon.crConstant Summary
-
CLIENT =
(ENV.fetch("MCAST_CLIENT_PORT", "1112")).to_i
-
CLIENT_SEND_INTERVAL =
(ENV.fetch("SHOUT_INTERVAL", "10")).to_i
-
CLIENT_TTL =
(ENV.fetch("CLEAN_INTERVAL", "30")).to_i
-
CONFIG_PATH =
(ENV.fetch("CONFIG_PATH", "/data/techlit/config.json")).to_s
-
HOST =
(ENV.fetch("MCAST_HOST", "224.0.3.111")).to_s
-
SAVE_INTERVAL =
(ENV.fetch("CLEAN_INTERVAL", "10")).to_i
-
SERVER =
(ENV.fetch("MCAST_SERVER_PORT", "1111")).to_i
-
SERVER_SEND_INTERVAL =
(ENV.fetch("SHOUT_INTERVAL", "10")).to_i
-
VERSION =
"0.1.0"
Class Method Summary
- .config
- .load_config
- .receive_from(port, &block : String, IP -> )
- .run_as_client
- .run_as_server
- .save_config
- .send_as(port, interval, &block : -> String)