Skip to content

Add priority: 1000 to ddev-expose-node-app-on-subdomain blog#646

Merged
stasadev merged 2 commits into
ddev:mainfrom
chx:patch-1
May 21, 2026
Merged

Add priority: 1000 to ddev-expose-node-app-on-subdomain blog#646
stasadev merged 2 commits into
ddev:mainfrom
chx:patch-1

Conversation

@chx
Copy link
Copy Markdown
Contributor

@chx chx commented May 21, 2026

As per traefik documentation:

To avoid path overlap, routes are sorted, by default, in descending order using rules length. The priority is directly equal to the length of the rule, and so the longest length has the highest priority.

rules length

It's easy for the HostRegexp rule to become longer than 100: a long hostname, and/or a couple additional hostnames and there it is. So suggest a priority of 1000 instead. Maybe we should suggest 100 000, even? The internal rules have 64 bit maxint priority so 100 000 is not outlandish.

I believe this to be incorrect, if you add something to additional hostnames it will be routed to the web container.
Comment on lines -38 to -46
In your project’s `.ddev/config.yaml`, define the project name and the additional hostname you want to use. For example:

```yaml
name: example

additional_hostnames:
- frontend.example
```

Copy link
Copy Markdown
Member

@stasadev stasadev May 21, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe this to be incorrect, if you add something to additional hostnames it will be routed to the web container. I think at least.

  1. additional_hostnames is needed for the SSL certificate frontend.example.ddev.site
  2. "It will be routed to the web container" - no, see priority: 100 in the Traefik config - it overrides the default route.

@github-actions
Copy link
Copy Markdown

🌐 Fork Preview for PR #646

https://pr-646.ddev-com-fork-previews.pages.dev

This preview updates automatically when you push changes to your fork.

Copy link
Copy Markdown
Member

@stasadev stasadev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you!

@stasadev stasadev changed the title Update ddev-expose-node-app-on-subdomain.md Add priority: 1000 to ddev-expose-node-app-on-subdomain blog May 21, 2026
@stasadev stasadev merged commit 0b8f378 into ddev:main May 21, 2026
2 checks passed
@github-actions
Copy link
Copy Markdown

PR closed. The Cloudflare Pages preview is no longer updated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants