Skip to content

fix: reject reused scheme:host pairs in port_mappings - #434

Merged
josegonzalez merged 1 commit into
mainfrom
432-reject-reused-scheme-host-pairs-in-port-mappings-offline
Aug 7, 2026
Merged

fix: reject reused scheme:host pairs in port_mappings#434
josegonzalez merged 1 commit into
mainfrom
432-reject-reused-scheme-host-pairs-in-port-mappings-offline

Conversation

@josegonzalez

Copy link
Copy Markdown
Member

Only one container port can be bound to a given scheme and host port, so dokku refuses a ports:add or ports:set whose mappings reuse one. dokku_ports accepted such a list and only failed once the command ran. Validate() now rejects a reuse within the recipe, which docket validate catches offline, and plan reports a mapping that collides with one already on the server instead of leaving it to apply. state: absent still accepts a reuse, matching ports:remove.

Closes #432

Only one container port can be bound to a given scheme and host port, so dokku refuses a `ports:add` or `ports:set` whose mappings reuse one. `dokku_ports` accepted such a list and only failed once the command ran. `Validate()` now rejects a reuse within the recipe, which `docket validate` catches offline, and `plan` reports a mapping that collides with one already on the server instead of leaving it to `apply`. `state: absent` still accepts a reuse, matching `ports:remove`.

Closes #432
@josegonzalez
josegonzalez merged commit c2e04b1 into main Aug 7, 2026
30 of 31 checks passed
@josegonzalez
josegonzalez deleted the 432-reject-reused-scheme-host-pairs-in-port-mappings-offline branch August 7, 2026 21:53
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.

Reject reused scheme:host pairs in port_mappings offline

1 participant