Class: FastlyCTL::LoggingSubCmd
- Inherits:
-
Thor
- Object
- Thor
- FastlyCTL::LoggingSubCmd
- Defined in:
- lib/fastlyctl/commands/logging.rb
Class Method Summary collapse
-
.banner(command, namespace = nil, subcommand = false) ⇒ Object
bit of a monkey patch to fix –help output.
Instance Method Summary collapse
Class Method Details
.banner(command, namespace = nil, subcommand = false) ⇒ Object
bit of a monkey patch to fix –help output
8 9 10 |
# File 'lib/fastlyctl/commands/logging.rb', line 8 def self.(command, namespace = nil, subcommand = false) "#{basename} logging #{command.usage}" end |
Instance Method Details
#bigquery(action) ⇒ Object
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 |
# File 'lib/fastlyctl/commands/logging.rb', line 29 def bigquery(action) case action when "create" BigQuery.create() when "list" BigQuery.list() when "update" BigQuery.update() when "show" BigQuery.show() when "delete" BigQuery.delete() else abort "Sorry, invalid action #{action} supplied, only create, update, delete and show are valid." end end |
#status ⇒ Object
60 61 62 63 64 |
# File 'lib/fastlyctl/commands/logging.rb', line 60 def status id = [:service] resp = FastlyCTL::Fetcher.api_request(:get, "/service/#{id}/logging_status") say(JSON.pretty_generate(resp)) end |