Guest User

Untitled

a guest
Dec 15th, 2018
120
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Ruby 0.32 KB | None | 0 0
  1.  
  2. hostname  = ARGV[0] || "10.32.8.234"
  3. port      = ARGV[1] || 4002
  4.  
  5. require './daemon.rb'
  6.  
  7.  
  8. msg = [
  9.   Time.now.to_i,
  10.   "Twitter",
  11.   "Fortune",
  12.   `fortune`,
  13.   nil]
  14.  
  15.   # File.open('lena.jpg', 'rb').read
  16.   # ]
  17.  
  18. 1.times{
  19.   success = MPPDaemon::Client.send(hostname, port, msg.dup)
  20.   puts "Succeeded? #{success}"
  21. }
Add Comment
Please, Sign In to add comment