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

Commit

Permalink
config: support overriding agent endpoint via env (#405)
Browse files Browse the repository at this point in the history
  • Loading branch information
LeoCavaille authored and Emanuele Palazzetti committed Apr 10, 2018
1 parent 418e72a commit 564d3dc
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions config/merge_env.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,10 @@ func mergeEnv(c *AgentConfig) {
c.HostName = v
}

if v := os.Getenv("DD_APM_DD_URL"); v != "" {
c.APIEndpoint = v
}

if v := os.Getenv("DD_API_KEY"); v != "" {
vals := strings.Split(v, ",")
for i := range vals {
Expand Down

0 comments on commit 564d3dc

Please sign in to comment.