how to run docker container while starting springboot application?

Viewed 22

I wanted to run my sqlserver container while starting my spring boot application and without launching the container from CMD (docker start sqlserver) or DockerDesktop so i can avoid "Connection Refused" error everytime i run the project while forgeting to launch the container. i want to invoke docker start sqlserver command while my springboot project starting . so do i need to do the configuration on application.yml or on the dockerfile the question is am i able to excute shell commands on a spring project if so how? thank you.

0 Answers
Related