Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Config: Add TELEMETRY_URL support for telemetry configuration #6237

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions docker/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,21 +34,22 @@ The following config.json overrides are applied:

The following environment variables can be supplied. Except when noted, it is possible to reconfigure deployments even after the data directory has been initialized.

| Variable | Description |
| -------- | ----------- |
| Variable | Description |
|-----------------|-----------------------------------------------------------------------------------------------------------------------------------------------------|
| NETWORK | Leave blank for a private network, otherwise specify one of mainnet, betanet, testnet, or devnet. Only used during a data directory initialization. |
| PROFILE | If set, initializes the config.json file according to the given profile. |
| PROFILE | If set, initializes the config.json file according to the given profile. |
| DEV_MODE | If set to 1 on a private network, enable dev mode. Only used during data directory initialization. |
| START_KMD | When set to 1, start kmd service with no timeout. THIS SHOULD NOT BE USED IN PRODUCTION. |
| FAST_CATCHUP | If set to 1 on a public network, attempt to start fast-catchup during initial config. |
| TOKEN | If set, overrides the REST API token. |
| ADMIN_TOKEN | If set, overrides the REST API admin token. |
| KMD_TOKEN | If set along with `START_KMD`, override the KMD REST API token. |
| TELEMETRY_NAME | If set on a public network, telemetry is reported with this name. |
| TELEMETRY_URL | The URL to send telemetry to if enabled (TELEMETRY_NAME is also required). Defaults to sending to Algorand. |
| NUM_ROUNDS | If set on a private network, override default of 30000 participation keys. |
| GENESIS_ADDRESS | If set, use this API address to initialize the genesis file. |
| GENESIS_ADDRESS | If set, use this API address to initialize the genesis file. |
| PEER_ADDRESS | If set, override phonebook with peer ip:port (or semicolon separated list: ip:port;ip:port;ip:port...) |
| GOSSIP_PORT | If set, configure the node to listen for external connections on this address. For example "4161" |
| GOSSIP_PORT | If set, configure the node to listen for external connections on this address. For example "4161" |

### Special Files

Expand Down
4 changes: 4 additions & 0 deletions docker/files/run/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,9 @@ function configure_data_dir() {
# configure telemetry
if [ "$TELEMETRY_NAME" != "" ]; then
diagcfg telemetry name -n "$TELEMETRY_NAME" -d "$ALGORAND_DATA"
if [ "$TELEMETRY_URL" != "" ]; then
diagcfg telemetry endpoint -e "$TELEMETRY_URL" -d "$ALGORAND_DATA"
fi
diagcfg telemetry enable -d "$ALGORAND_DATA"
elif ! [ -f "/etc/algorand/logging.config" ]; then
diagcfg telemetry disable
Expand Down Expand Up @@ -213,6 +216,7 @@ echo " TOKEN: ${TOKEN:-"Not Set"}"
echo " ADMIN_TOKEN: ${ADMIN_TOKEN:-"Not Set"}"
echo " KMD_TOKEN: ${KMD_TOKEN:-"Not Set"}"
echo " TELEMETRY_NAME: $TELEMETRY_NAME"
echo " TELEMETRY_URL: $TELEMETRY_URL"
echo " NUM_ROUNDS: $NUM_ROUNDS"
echo " GENESIS_ADDRESS: $GENESIS_ADDRESS"
echo " PEER_ADDRESS: $PEER_ADDRESS"
Expand Down
Loading