Skip to main content

Get more information about your running service or process in development

Learn how to track the events and logs of your services and processes to know what's happening.

Updated over a month ago

Context


When developing your service or process on EDITO, you might run into some unexpected behavior for your chart. From the EDITO Datalab, you can easily access your namespace events by clicking on the “Events” button from “My services” or “My processes”, and a running service logs by clicking on the name on its tile in “My services”.

Still, to understand better what is going on under the hood, you can also run some commands from inside a service that could help you. We will show some basic examples, but you can always learn more in the official Kubernetes documentation.

To do so, you need a terminal on EDITO with the “edit” or “admin” Kubernetes roles: for example, you can launch a Jupyter-python with “edit” role.

First, you can start by listing the pods running in your namespace:

kubectl get pods

Then, you can print a detailed description of a selected pod by running:

kubectl describe pods/my-pod-xxxxxx-x

It can be useful if your pod does not start.

If your pod has started, you can get its logs by running:

kubectl logs my-pod-xxxxxx-x --all-containers=true

📌 Note: you can use the --container container-name option to target a specific container.

Sometimes logs aren't enough, and you would want to run commands directly on your container. This is possible with the kubectl exec command. To get a shell in your running container, simply run:

kubectl exec --stdin --tty my-pod -- /bin/bash

📌 Note: this assume bash is available in your container, but any other available shell would work.

If your service/process won’t launch from the Datalab


You might run into an issue where your service/process won’t launch from the Datalab, without an explicit error to debug.

If you cannot even access the launcher page of your service/process, you probably have a malformed chart. You can try to open the debug console of your browser which might hint you where the error might be.

If you can access the launcher page but cannot launch your service/process, you might try to manually install your chart.

  1. First, you need a terminal on EDITO with the “edit” or “admin” Kubernetes roles; for example, you can launch a Jupyter-python with “edit” role.

  2. Then, you can go on the launcher page of the service/process you are developing and expand the command bar showing Helm commands. There should be three commands:

    1. The first one to add the Helm repository, starting with helm repo add ...

    2. The second one creating a file with your values, starting with cat <<EOF > ./values.yaml ...

    3. The last one installing your chart, starting with helm install ...

  3. Copy and run those three commands in the Jupyter-python terminal, and the last one should give you a better hint as to why your service/process is crashing.

What's next?


If you have any questions, problems, or suggestions, please feel free to contact us via chat using the widget available at the bottom right of the page.

Did this answer your question?