Skip to content

Instantly share code, notes, and snippets.

@dw
Created February 13, 2018 14:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dw/4bc7010afc37e4b1bbe860319803e3c9 to your computer and use it in GitHub Desktop.
Save dw/4bc7010afc37e4b1bbe860319803e3c9 to your computer and use it in GitHub Desktop.
import mitogen
import requests
def get_url(url):
return requests.get(url).text
@mitogen.main()
def main(router):
host = router.ssh(hostname='k3')
print host.call(get_url, 'https://www.google.com/')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment