resources/old-gaisr.rb
def remote_cmd (upload_type, infile)
  server = "http://roz.bc.edu:8080"
  base_url = server + "/mlab/upld"
  return RestClient.post(base_url,
                         {"upload-type" => upload_type,
                           :subtype => "remote",
                           :user => ENV['LOGNAME'].downcase,
                           :host => ENV["HOST"],
                           :file => File.new(infile)},
                         {:cookies => {:user => ENV['LOGNAME'].downcase}})
end
### run-config and check-sto currently local here.  May split these
### out as separate commands as well.
run-config and check-sto currently local here.  May split these
out as separate commands as well.
run - config and check - sto currently local here . May split these out as separate commands as well .
def remote_cmd (upload_type, infile)
  server = "http://roz.bc.edu:8080"
  base_url = server + "/mlab/upld"
  return RestClient.post(base_url,
                         {"upload-type" => upload_type,
                           :subtype => "remote",
                           :user => ENV['LOGNAME'].downcase,
                           :host => ENV["HOST"],
                           :file => File.new(infile)},
                         {:cookies => {:user => ENV['LOGNAME'].downcase}})
end
def remote_cmd ( upload_type , infile ) server = "http://roz.bc.edu:8080" base_url = server + "/mlab/upld" return RestClient . post ( base_url , { "upload-type" => upload_type , :subtype => "remote" , :user => ENV [ 'LOGNAME' ] . downcase , :host => ENV [ "HOST" ] , :file => File . new ( infile ) } , { :cookies => { :user => ENV [ 'LOGNAME' ] . downcase } } ) end
run-config and check-sto currently local here.
run - config and check - sto currently local here .
upload_type
infile