From the audit against the canonical REPO_POLICIES.md, verified against main at 61f42e6.
The policy states:
> Dockerized web services listen on port 8080 by default, overridable with PORT.
The default half is correct: DefaultPort = 8080 (internal/config/config.go:23) and EXPOSE 8080 (Dockerfile:76). The override half does not exist. config.go:104 reads Port: loader.intVal("port", DefaultPort) — YAML file only. A grep for Getenv across internal/ and cmd/ returns exactly three hits, all in config.go: PIXA_CONFIG_PATH (line 340) and HOME twice (lines 355-356). There is no PORT handling anywhere.
This bites in exactly the deployment the policy is written for. Dockerfile:78's ENTRYPOINT hardcodes --config /etc/pixa/config.yml, so changing the listen port in a container today means bind-mounting a whole replacement config file — for one integer. Container platforms conventionally inject PORT, and this is a prerequisite for a clean uPaaS deployment (#17).
Definition of done
PORT overrides the config-file value and the default. Precedence documented explicitly (suggest: PORT env > config file > default, so the platform can always win).
An unparseable PORT must abort startup naming the variable and the offending value. Repo policy is explicit that a set-but-invalid explicit value never silently falls back to a default — PORT=banana must not quietly become 8080. Use the same strict-parsing pattern as the config getters.
Range validation matches whatever the config file path already enforces, so the two entry points cannot disagree about what a valid port is.
Decide whether other keys deserve the same treatment or whether PORT is a deliberate special case (the policy names only PORT). Note the env: section that smartconfig already provides is a related but different mechanism — see #75, which documents it. Say in the PR how the two interact, so operators are not left guessing which wins.
Failing tests first: PORT=9090 takes effect over a config file specifying 8080; PORT=banana exits non-zero naming the variable; absent PORT leaves existing behavior unchanged.
README.md and config.example.yml document the override. make check green.
Coordination
Touches internal/config/config.go, which PR #54 conflicts with heavily (it rewrote that file for lint conformance after absorbing #53). Do after#54 merges.
From the audit against the canonical `REPO_POLICIES.md`, verified against `main` at `61f42e6`.
The policy states:
> Dockerized web services listen on port 8080 by default, overridable with `PORT`.
The default half is correct: `DefaultPort = 8080` (`internal/config/config.go:23`) and `EXPOSE 8080` (`Dockerfile:76`). The override half does not exist. `config.go:104` reads `Port: loader.intVal("port", DefaultPort)` — YAML file only. A grep for `Getenv` across `internal/` and `cmd/` returns exactly three hits, all in `config.go`: `PIXA_CONFIG_PATH` (line 340) and `HOME` twice (lines 355-356). There is no `PORT` handling anywhere.
This bites in exactly the deployment the policy is written for. `Dockerfile:78`'s `ENTRYPOINT` hardcodes `--config /etc/pixa/config.yml`, so changing the listen port in a container today means bind-mounting a whole replacement config file — for one integer. Container platforms conventionally inject `PORT`, and this is a prerequisite for a clean uPaaS deployment (#17).
## Definition of done
1. `PORT` overrides the config-file value and the default. Precedence documented explicitly (suggest: `PORT` env > config file > default, so the platform can always win).
2. **An unparseable `PORT` must abort startup** naming the variable and the offending value. Repo policy is explicit that a set-but-invalid explicit value never silently falls back to a default — `PORT=banana` must not quietly become 8080. Use the same strict-parsing pattern as the config getters.
3. Range validation matches whatever the config file path already enforces, so the two entry points cannot disagree about what a valid port is.
4. Decide whether other keys deserve the same treatment or whether `PORT` is a deliberate special case (the policy names only `PORT`). Note the `env:` section that smartconfig already provides is a related but different mechanism — see #75, which documents it. Say in the PR how the two interact, so operators are not left guessing which wins.
5. Failing tests first: `PORT=9090` takes effect over a config file specifying 8080; `PORT=banana` exits non-zero naming the variable; absent `PORT` leaves existing behavior unchanged.
6. `README.md` and `config.example.yml` document the override. `make check` green.
## Coordination
Touches `internal/config/config.go`, which PR #54 conflicts with heavily (it rewrote that file for lint conformance after absorbing #53). Do **after** #54 merges.
clawbot
added this to the 1.0.0 milestone 2026-08-09 07:04:27 +02:00
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
From the audit against the canonical
REPO_POLICIES.md, verified againstmainat61f42e6.The policy states:
> Dockerized web services listen on port 8080 by default, overridable with
PORT.The default half is correct:
DefaultPort = 8080(internal/config/config.go:23) andEXPOSE 8080(Dockerfile:76). The override half does not exist.config.go:104readsPort: loader.intVal("port", DefaultPort)— YAML file only. A grep forGetenvacrossinternal/andcmd/returns exactly three hits, all inconfig.go:PIXA_CONFIG_PATH(line 340) andHOMEtwice (lines 355-356). There is noPORThandling anywhere.This bites in exactly the deployment the policy is written for.
Dockerfile:78'sENTRYPOINThardcodes--config /etc/pixa/config.yml, so changing the listen port in a container today means bind-mounting a whole replacement config file — for one integer. Container platforms conventionally injectPORT, and this is a prerequisite for a clean uPaaS deployment (#17).Definition of done
PORToverrides the config-file value and the default. Precedence documented explicitly (suggest:PORTenv > config file > default, so the platform can always win).PORTmust abort startup naming the variable and the offending value. Repo policy is explicit that a set-but-invalid explicit value never silently falls back to a default —PORT=bananamust not quietly become 8080. Use the same strict-parsing pattern as the config getters.PORTis a deliberate special case (the policy names onlyPORT). Note theenv:section that smartconfig already provides is a related but different mechanism — see #75, which documents it. Say in the PR how the two interact, so operators are not left guessing which wins.PORT=9090takes effect over a config file specifying 8080;PORT=bananaexits non-zero naming the variable; absentPORTleaves existing behavior unchanged.README.mdandconfig.example.ymldocument the override.make checkgreen.Coordination
Touches
internal/config/config.go, which PR #54 conflicts with heavily (it rewrote that file for lint conformance after absorbing #53). Do after #54 merges.