Seems like this tutorial for basic Apache with php-fpm which I followed works fine.
I'm having some hard time on how I can build same using docker container running with basic wordpress, lots of tags seems to be confusing on which one to use. I already tried downloading docker images like wordpress:6.3.1-php8.2-apache but still no idea on how to link it on a separate running container wordpress:6.3.1-php8.2-fpm
You can take a look at this repo for some tips on getting the fpm version working:
The Apache image can be exposed directly and does not require any sore of reverse proxy. If you want greater control, you can utilize the fpm version which requires a reverse proxy to serve the files.