sprintcube / docker-compose-lamp

A basic LAMP stack environment built using Docker Compose.
MIT License
2.54k stars 1.39k forks source link

[QUESTION] Why are the `werbserver` and `database` containers set to run when host machine boots? #268

Open govarthenan opened 3 months ago

govarthenan commented 3 months ago

In the docker-compose.yaml, the two aforementioned containers are configured restart: "always". This makes both of those containers to compose and start automatically after my laptop boots.

Is this the intended behavior? If yes/no please explain why it was configured in such a way.

tinodesigns commented 3 months ago

I personally like ti that way, I have it on a homeserver and want it to be reachable all the time in my network. Also this could be easily changed, no?

govarthenan commented 3 months ago

@tinodesigns I understand why one might want those containers to autostart.

Do you have any idea how to stop this autostarting behavior? Because the last time I set restart: "unless-stopped", the stack seemed to crash for some reason.

tinodesigns commented 3 months ago

@govarthenan sorry I'dn't know that. I'm a bit new to docker myself. May be someone else can help here?