I have a spring boot app running in docker which have playwright code for retrieving data from some websites.
In the old form of my app arch I had my spring boot app running with selenium driver and connected to standalone selenium grid, all worked fine.
Currently, I would like to migrate to playwright as it is more powerful and I am able to connect over CDP to listen for network requests and responses. My intention is to to have my spring boot app to connect remotely to a playwright docker.
I went through playwright documentation here /java/community/welcome and besides having a small section on docker (/java/docs/docker) it is not clear if I am even able to setup such an environment and whether it is supported.
I tried to clone the git repository and run a docker container just for the POC but it failed with the error below:
18.75 The JAVA_HOME environment variable is not defined correctly,
[+] Running 0/1ronment variable is needed to run this program.
So, I am probably missing something and I think is is not suppose to be this complex to set up such an environment.
This is the desired setup
$SpringBoot-App$ -----> $Playwright-Docker$ -----> $Website$
If anyone managed to setup such an environment and could give tips and input it will be appreciated.