Skip to content

Conversation

swalha1999
Copy link

@swalha1999 swalha1999 commented Jul 28, 2025

  • Add isWildcard boolean column to domains table via Drizzle migration
  • Update Traefik configuration to use HostRegexp for wildcard patterns
  • Skip DNS validation for wildcard domains to avoid validation issues
  • Add wildcard toggle switch in domain creation UI
  • Add wildcard indicator badge with tooltip in domain display
  • Support patterns like *-dev.swalha.com routing to single application

this is like Subdomains for tenants like in Vercel multi tenant and Wildcard Domains

@swalha1999 swalha1999 requested a review from Siumauricio as a code owner July 28, 2025 17:07
@swalha1999
Copy link
Author

image image

Copy link
Contributor

@Siumauricio Siumauricio left a comment

Choose a reason for hiding this comment

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

This implementation is missing on the docker compose which are handled by labels

you can see the packages/server/src/utils/docker/domain.ts file, Line 310 For reference

@swalha1999 swalha1999 requested a review from Siumauricio August 2, 2025 22:18
@@ -0,0 +1 @@
ALTER TABLE "domain" ADD COLUMN "isWildcard" boolean DEFAULT false NOT NULL;
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you drop the migrations and generate again the migrations?

Copy link
Author

Choose a reason for hiding this comment

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

done

@swalha1999 swalha1999 requested a review from Siumauricio August 10, 2025 21:18
@Siumauricio
Copy link
Contributor

Can you add docs for this wildcard domains? https://github.com/Dokploy/website ?

@swalha1999
Copy link
Author

just made a pull requist to the docs

Copy link
Contributor

@Siumauricio Siumauricio left a comment

Choose a reason for hiding this comment

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

Can you fix the CI/CD linter?

And add a few cases in the test in these files?

  1. Compose domains (apps/dokploy/test/compose/domain/labels.test.ts)
  2. Applications (apps/dokploy/test/traefik/traefik.test.ts)

to cover this cases when the isWildcard is enabled?

- Added comprehensive test coverage for isWildcard functionality
- Tests cover basic wildcard patterns, complex patterns, HTTPS redirects, certificates, and middleware combinations
- Ensures wildcard domains generate proper HostRegexp rules instead of Host rules
@swalha1999 swalha1999 requested a review from Siumauricio August 14, 2025 18:39
@Siumauricio
Copy link
Contributor

Can you check the tests?

@swalha1999

@Siumauricio
Copy link
Contributor

@swalha1999 this is still on progress?

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