How to assign subdomain to docker compose application?
Im playing around with compose feature, following docs from here https://docs.dokploy.com/en/docker-compose/example
For me it seems that traefic labels do nothing. I was trying to deploy https://github.com/Dokploy/docker-compose-test/blob/main/docker-compose.yml example app but it traefic service and configuration is not affected.
I also see cryptic errors in docker logs for dokploy like
Not sure if its related...
Currently Im editing traefic config files in
dynamic/
myself to assign hosts, not ideal. Would be great to have a way to assign a subdomain to a port in a nice wayExample
Learn how to use Docker Compose with Dokploy
GitHub
docker-compose-test/docker-compose.yml at main ยท Dokploy/docker-com...
Contribute to Dokploy/docker-compose-test development by creating an account on GitHub.

18 Replies

share your main traefik config
1. the docker compose build were succesfully?
2. the application is running and do you see any logs?
if you had dokploy installed before version v0.2.0, you have to make these changes manually to be able to use docker compose with traefik https://github.com/Dokploy/dokploy/releases/tag/v0.2.0
GitHub
Release v0.2.0 ยท Dokploy/dokploy
What's Changed ๐๐
Docker compose support by @Siumauricio in #111
Add calcom, pocketbase and plausible templates to the directory
Docker Compose Support
We introduce docker compose support, d...
Can you share docker compose configuration
Sorry, @๐ ๐ฟ๐ญ๐๐น๐ฎ๐๐ฒ , do you mean
docker-compose.yml
file? It is this one https://github.com/Dokploy/docker-compose-test/blob/main/docker-compose.ymlGitHub
docker-compose-test/docker-compose.yml at main ยท Dokploy/docker-com...
Contribute to Dokploy/docker-compose-test development by creating an account on GitHub.
Here is build log from
have you check this?

No, I just reinstalled dokploy to have fresh install
so its 0.2.2 version
did you modify the labels of the docker compose?
No, used as is

Follow the example, if you had any questions let me know!: https://docs.dokploy.com/en/docker-compose/example#tutorial
Example
Learn how to use Docker Compose with Dokploy
I think example is a bit misleading:
-
your-domain.com
and next-app
on the screenshot from cloudflare panel are different values
- even if you have example in github you cant use it as is to because host is hardcoded
- you actually need to fork repo, edit it, commit, and then use it in dokploy
I think there is no way traefik.http.routers.<unique-name>.rule
value might be configurable from ui? as its parsed before docker buildIt is clear, you will not use the same domain of your-domain.com and use next-app as an example that I put in the cloudflare, and it is clear that you can not use the same example that's why it mentions that you make a fork, and there is a section that mentions you need to modify the existing docker compose file,
We could do something similar, however we prefer to keep the docker compose standard and not alter its behavior internally, so you have full control of your file.
Finally I managed to make this labels for trafic actualy work. For this I had to reinstall docker as previous installation of dokploy somehow affected
Here, I created simplier compose example that you may use in docs
Managed to make it work on my machine https://todo.dokploy.kcrz.dev/
Guess, this question is no longer relevant, as this issue was caused (most likely) by my previous dokploy install.
So if something works buggy โ reinstall docker
congrats, I don't know if you read the release notes
no