refactor: clarify fixed container port with containerAppPort constant

The container always listens on 8080 internally while the user-provided
port is only the host-side mapping. Make this explicit without changing
behavior or the generated config:

- add a named containerAppPort constant and use it in both the docker -p
  mapping and the config.toml generation (was a bare 8080 literal in two
  places)
- document why config.toml hardcodes the port, so it isn't "fixed" back
  to the form value
- relabel the form field to "Porta (host)"

The generated config.toml is byte-identical (port = 8080).

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
jb
2026-06-19 12:00:54 -03:00
co-authored by Claude Opus 4.8
parent 6becd3462d
commit d2717de47a
4 changed files with 12 additions and 5 deletions
+1 -1
View File
@@ -172,7 +172,7 @@ func InitialModel() Model {
serverForm: NewFormStep("Servidor", []FormField{
{
Id: "port",
Label: "Porta",
Label: "Porta (host)",
Placeholder: "8081",
Default: strconv.FormatInt(cfg.Server.Port, 10),
Type: FieldTypeNumber,