jolicode / docker-starter

🏗️ A skeleton to start a new web project with PHP, Docker and Castor
MIT License
337 stars 34 forks source link

Add array_unique on urls listing #290

Closed MarionLeHerisson closed 7 months ago

MarionLeHerisson commented 7 months ago

When running castor start, on some projects, the same url is displayed multiple times, for instance :

Available URLs for this project:
--------------------------------

 * https://foodomarket.local
 * https://elasticsearch.foodomarket.local
 * https://kibana.foodomarket.local
 * https://redis.foodomarket.local
 * https://foodomarket.local
 * https://foodomarket.local

=> "https://foodomarket.local" displayed 3 times

lyrixx commented 7 months ago

hmm, It would have been better to check why there are the same URL many times! I never hit this "bug", so I guess it comes from your projet.

pyrech commented 7 months ago

For the record, it can happen if one of your service is declaring an host matching the "root_domain", f.e. when your frontend service does not use a subdomain.

Already got this on a few projects but didn't took time to fix it.

pyrech commented 6 months ago

About this issue, my previous comment explained why we listed two times foodomarket.local (root_domain configuration + frontend's domain)

But I just understood that the third repetition of foodomarket.local is due to the configuration rule handling the redirect from HTTP to HTTPS.