class KBE::CLI::LogsCommand

Public Instance Methods

execute() click to toggle source
# File lib/kbe/cli/logs_command.rb, line 14
def execute
  pod = KBE.pod_by(selector_or_pod, only_running: false)
  parts = []
  parts << "logs --tail=10 -f #{pod}"
  parts << "-c #{container}" if container # let error because it gives the list

  KBE.kubectl parts.join(" ")
end