Skip to content

cleanup: drop log and smoketest pimp#112

Open
Bierchermuesli wants to merge 1 commit into
netdisco:masterfrom
Bierchermuesli:cleanup/log-volume-mount
Open

cleanup: drop log and smoketest pimp#112
Bierchermuesli wants to merge 1 commit into
netdisco:masterfrom
Bierchermuesli:cleanup/log-volume-mount

Conversation

@Bierchermuesli
Copy link
Copy Markdown
Contributor

@Bierchermuesli Bierchermuesli commented Apr 30, 2026

Now that netdisco/netdisco#1500 (skip log file redirection in foreground mode) is in netdisco master:

  • docker-compose.yml: drop the ./netdisco/logs:/home/netdisco/logs bind mount on both netdisco-backend and netdisco-web. The mount served only to materialise the netdisco-*.log -> /dev/stdout symlink target on the host
  • README: adjust log refreences
  • .github/workflows/smoke-test.yaml: add an assertion that /home/netdisco/logs has no logs.

The two ln -s /dev/stdout /home/netdisco/logs/netdisco-*.log symlinks in netdisco-base/Dockerfile are retained. They cost nothing in foreground mode (unused), and they preserve correct behaviour for anyone who overrides CMD to run the daemons in non-foreground / start mode. Their presence also lets this PR merge independently of the netdisco release schedule: published images that are still on netdisco 2.098002 (pre-#1500) will continue to work because the symlinks still route their log writes to container stdout.

Suggest holding this open until at least one published netdisco-docker image build from a netdisco release #1500 has shipped, so users who pull :latest after the merge see the new behaviour end-to-end. The image keeps working in the meantime regardless.

Test plan

  • Smoke test workflow runs green on this PR (default args = current netdisco master, post-#1500)
  • Manually trigger workflow_dispatch against netdisco_git_url=https://github.com/netdisco/netdisco.git, committish=2.098002 (pre-#1500) and verify the new "no real log files" assertion correctly fails — proving the regression catcher works
  • After merge, confirm `docker compose upno longer requiresmkdir netdisco/logsanddocker compose logs` still shows daemon output

…test

- Remove ./netdisco/logs:/home/netdisco/logs volume from netdisco-backend
  and netdisco-web in docker-compose.yml. With netdisco/netdisco#1500,
  foreground mode writes logs directly to stdout — the host-side bind
  mount served no purpose other than to dirty the host filesystem with
  an empty 'logs' directory.
- README: drop 'logs' from the mkdir helper, and replace 'Logs are
  available in netdisco/logs/' with a pointer to 'docker compose logs'.
- Smoke test: assert that no real *.log files exist in /home/netdisco/logs/
  in either container after boot. Excludes the legacy
  netdisco-*.log -> /dev/stdout symlinks (which we keep as a safety net
  for non-foreground use), so any *real* file means the daemons have
  regressed to writing log files instead of stdout — i.e. it would catch
  a future revert of #1500.

Hold this PR until netdisco cuts a release that includes #1500
(2.098002 was cut before #1500 merged); the legacy stdout symlinks in
netdisco-base/Dockerfile are intentionally retained so this PR remains
safe to merge whenever convenient.
@Bierchermuesli Bierchermuesli changed the title cleanup: drop log volume mount; harden smoke test against real log files cleanup: drop log and smoketest pimp Apr 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant