This is a brief guide on how to capture logs of the HTTPS requests that Appsmith executes when we execute a query. This can help to debug problems with the APIs executed by users.
All the commands executed in the steps that we show below must be executed within the shell of the pod where Appsmith is hosted.
- Enabled Ubuntu repositories.
sudo add-apt-repository main
sudo add-apt-repository universe
sudo add-apt-repository restricted
sudo add-apt-repository multiverse
- Run the following command to update the repositories.
sudo apt-get update
- Install the tcpflow package with the following command.
sudo apt-get install tcpflow
- We will create a folder called
NetLogs
, and we will enter it follow the following commands.
mkdir NetLogs
cd NetLogs
- Now we execute the https requests listener on the port that it is executed on.
tcpflow -p -c port 443 | tee NetLogs.log
-
This will be put in listening format and reports the movements in an
.log
file that will be saved in theNetLogs
folder. -
now run a query in appsmith.
-
Now we will get the results of our NetLogs with the following command.
cat NetLogs.log
- Now we will copy the resulting information and put it into a file with the
.log
extension on our local machine.