-
Notifications
You must be signed in to change notification settings - Fork 8
Debugging a stack application
Scott Kurz edited this page Apr 30, 2021
·
2 revisions
-
Push your app in "debug" mode
odo push --debug
Note: The default odo debug port 5858 will be used.
-
Setup port forwarding from your cluster to your local workspace
Using odo:
odo debug port-forward
A specific local port can be specified with the
--local-port
flagUsing kubectl:
kubectl port-forward <pod_name> 5858:5858
-
Connect a debugger to localhost:5858 (or whatever local port you forwarded to)
-
Add
-Dmaven.failsafe.debug
to test command -
Push your app to your cluster
odo push
-
Forward the Maven default debug port (5005) from your cluster to your local workspace
kubectl port-forward <pod_name> 5005:5005
-
Run your tests
odo test --show-log
-
Connect a debugger to localhost:5005