Dokploy / Dokploy/dokploy

Add UI to manage Traefik basic auth middlewares

Open
#4,284 0 comments 4 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
TypeScript
Stars
37.4k
Forks
3k
Avg merge
1d 3h
Merged PRs (30d)
73

Description

What problem will this feature address?

Dokploy lets Applications manage basic auth through the Advanced → Security UI, but there is no equivalent for Docker Compose apps. For a compose service today, the only path is:

  1. SSH into the host
  2. Manually edit /etc/dokploy/traefik/dynamic/middlewares.yml
  3. Generate a bcrypt hash (e.g. htpasswd -nbB admin pass)
  4. Paste the entry in
  5. Reference it from compose labels or the domain's Middlewares field

This is a lot of friction for the common "I just want a quick login prompt on this compose service" case, and it's error-prone (YAML indentation, manual bcrypt, $ escaping in compose labels).

Describe the solution you'd like

Add a "Basic Auth Middlewares" card to the existing Traefik dashboard page (/dashboard/traefik) that lets the user:

  • List existing basicAuth entries in middlewares.yml (name + usernames only — never the hash)
  • Create a new entry from a form (name + username + password; password bcrypt-hashed server-side)
  • Delete an entry
  • Copy the <name>@file reference to paste into a compose label or a domain's Middlewares field

The feature is intentionally generic — not coupled to any specific application or compose. The user pastes the reference where they want it and redeploys themselves. No DB schema change, no migration, no redeploy coordination.

Describe alternatives you've considered

None.

Additional context

Works locally against the dev instance. Implementation is ~470 lines, additive (no changes to existing routers or DB).

Will you send a PR to implement it?

Yes

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the existing /dashboard/traefik page and trace how it reads or manages Traefik configuration. Inspect /etc/dokploy/traefik/dynamic/middlewares.yml and the compose labels or domain Middlewares field described in the issue. Done means the dashboard can list names and usernames, create and delete basicAuth entries, hash passwords server-side, and copy the @file reference without exposing hashes.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker-compose, typescript
Domain
devops, full-stack
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.