Class: Ploy::Command::Oracle

Inherits:
Base
  • Object
show all
Defined in:
lib/ploy/command/oracle.rb

Instance Method Summary collapse

Instance Method Details

#helpObject



38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# File 'lib/ploy/command/oracle.rb', line 38

def help
  return <<helptext
usage: ploy oracle [dir]

Examples:

  $ ploy oracle /etc/ploy/metadata.d

Summary:

  The oracle command starts up an http server. When it receives a GET request, it
  will read all of the metadata files in [dir] and return the data in them to
  the client as json.

helptext
end

#run(argv) ⇒ Object



35
36
37
# File 'lib/ploy/command/oracle.rb', line 35

def run(argv)
  OracleServer.oracle_run Ploy::MetaSrc.new(argv.shift || '/etc/ploy/metadata.d')
end