Skip to content

Instantly share code, notes, and snippets.

@kyle-eshares
Created March 1, 2016 17:05
Show Gist options
  • Save kyle-eshares/9f52be4c1789bad2afb6 to your computer and use it in GitHub Desktop.
Save kyle-eshares/9f52be4c1789bad2afb6 to your computer and use it in GitHub Desktop.
defmodule SimpleTCP do
use Application
def start(_type, _args) do
import Supervisor.Spec, warn: false
children = [
worker(SimpleTCP.Worker, [8000])
]
opts = [strategy: :one_for_one, name: SimpleTCP.Supervisor]
Supervisor.start_link(children, opts)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment