Skip to content

Instantly share code, notes, and snippets.

@5HT
Created December 10, 2013 21:29
Show Gist options
  • Save 5HT/7900535 to your computer and use it in GitHub Desktop.
Save 5HT/7900535 to your computer and use it in GitHub Desktop.
Erlang SSH
-module(x).
-export([exec/1]).
exec(A) -> spawn(fun() -> io:format("~p\n", [A]), exit(normal) end).
Node1:
> B=ssh_sample_cli:listen(8323, [{subsystems, []}, {exec, x, exec, ""]).
Node2:
$ ssh -p 8323 to.the.host 'lists:reverse("test").'
Node1:
"list:reverse(\"test\")."
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment