Created
December 19, 2016 04:14
-
-
Save patrobinson/4422a241d0e1164e6f29adbca0439269 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
defmodule DogStatsdSupervisor do | |
use Supervisor | |
def start_link do | |
Supervisor.start_link(__MODULE__, :ok) | |
end | |
def init(:ok) do | |
children = [ | |
worker(DogStatsd, [%{host: "localhost", port: 8125}, [name: DogStatsd]]), | |
] | |
supervise(children, strategy: :one_for_one) | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment