spring boot application did not start on raspberry pi
I would start by just trying to connect to the DB with psql. See whether the port was bound(-p 5432:5432). I would also recommend creating a container from your application in order to make the database private. Create a network and add the DB and your application in it so that your application is the only thing that has access to it. bear in mind that the url of the DB will change to the name or alias of the container. You can read more about that in Docker compose guides. Then bind the 8081 port of your application to the 8081 port of the raspberry. Thus exposing it so you can use your application. In that way you will not have to manually manage the java versions on your raspberry but rather in the docker image of your application.