Overpass-API icon indicating copy to clipboard operation
Overpass-API copied to clipboard

`OVERPASS_STOP_AFTER_INIT` ignored even when `OVERPASS_MODE=init` is set

Open bastien8060 opened this issue 2 months ago • 1 comments

Description: If you set OVERPASS_MODE=init together with OVERPASS_STOP_AFTER_INIT=true, you’d expect the container to just run init mode and then exit. That’s the whole point of the flag.

Right now that’s not what happens. If the DB is already initialized, the entrypoint just skips the init step and then runs the server anyway. The flag gets ignored. That makes the idea of OVERPASS_MODE=init inconsistent. The mode says “init only,” but in practice it sometimes turns into “serve,” depending on state. The flag is effectively bypassed.

Fix: OVERPASS_STOP_AFTER_INIT should always be checked when OVERPASS_MODE=init, regardless of whether actual initialization work is needed.

Reference: See #150, which moves the check so the flag is always respected.

bastien8060 avatar Sep 16 '25 12:09 bastien8060

I fixed it myself at #150 (!)

bastien8060 avatar Sep 16 '25 12:09 bastien8060