I’m trying to set up lizmap on a Debian server.
I would like to dockerize lizmap as well as other software that will allow to manage docker and my db (portainer, pgadmin, cloud cmd).
I made my docker-compose.yml file and when I launch it on my computer everything works as it should.
The problem is when I run docker-compose up --build on my Debian server, when I try to access one of the services via the web it doesn’t work.
I tried to go through
localhost:<defined port> as well as
<ip of the server>:<defined port> and it doesn’t work.
I’ve been going around in circles for several days and I can’t find the answer to my problem on google.
Here’s my docker-compose.yml file:
And my server is under Debian 10 Buster
Thanks for reading and if anyone has a solution, i’ll be grateful.
Where did you try tried this? On the server or on your machine? I mean, localhost will work only from your server, obviously, so I suppose you tried there, but that should work fine. If you try with an IP address locally from the server, that should work too, if that service is listening on that IP address.
If you try an IP address from your machine, even if you forwarded ports to the containers, firewalls can prevent you to access those ports externally.
Does it happen with all of yous services?
PS.: Make sure you use the
</> button to insert codes like xml tags. Your placeholders were removed by the forums filters. I fixed your post.
I tried localhost: on my machine (when i docker-compose up on my machine) and it worked just fine, but when i try it on my server it doesn’t work (docker-compose up on my server). (I use Bitwise to access my server). Also when i try :, sometimes it works and i can access my web container (it’s just a string saying hello world), and i can access portainer, pgAdmin, cloud cmd and when i use the command pg_isready -h localhost -p 5432 i have the accepting connexion message. But sometimes it won’t work and i don’t know why. The container who seems to work each time is portainer. But the real problem is with Lizmap, in localhost from my machine it works but when i launch it on the server and try to access it, nothing.
And i’m sorry, i thought i user the </> button, thanks for fixing my post
No, you still don’t use that. Now I leave your message unedited so you can see that why we can’t see some parts of your message.
It could be a network issue on your server. For example bad routing. If portainer is always available and other containers not, then it could be a reverse proxy forwarding request randomly to a wrong container. I can happen when you have multiple container with the same name on the same custom Docker network in different Docker Compose projects. For example when you name a container “web” in project “mysite1” but you have an other container with the same name in project “mysite2”.
If you try to accesss the db on localhost that should always work unless your db is restarting or something like that