What are my options for collecting logs?

Before you start shipping your application to customers, it is critical to have your support bundle spec with the needed collectors that will allow your team to troubleshoot common issues.

For most folks, it is all about collecting the right logs and files and there are several options depending on what you need to collect (clink on the included links for documentation on each option):

  • Pod Logs: This collector allows you to collect the pod logs based on label selector. Please note that if you include more than one label selector it means both labels must match.

  • Copy File: This collector allows you to grab a file that is running inside a container. This could be a log generated by the app or configuration files. You can also grab files from the (host)[Copy Files and Directories from Hosts - Troubleshoot Docs - Troubleshoot Docs].

  • Executing a Command: This collector allows you to exec into a container in a given pod. The command output is collected in JSON format. It is important to consider the command you wish to run and if it will be available/installed on the specified container.

  • Run Pod: This collector allows you to run a container inside a pod that performs an action. If the command you wish to run is not available/installed in a running pod, you can use this collector to run a container that has the proper software installed. Note that this container must be publicly available.