Skip to content

Installer: status, stop, start and uninstall commands (#372) - #381

Merged
rbardaji merged 2 commits into
mainfrom
feature/372-lifecycle-commands
Oct 23, 2026
Merged

rbardaji merged 2 commits into
mainfrom
feature/372-lifecycle-commands

Conversation

@rbardaji

Copy link
Copy Markdown
Collaborator

Closes #372.

What

install.sh status | stop | start | uninstall [--remove-data] [--yes] [--instance <name>] works from a checkout, or from the web against the installed checkout. From the web, nothing is fetched or moved. Everything is found by the Compose project labels.

  • status reports: instance, project, installer version, catalog, containers, port, /health, NetBird and the CKAN set up for the Endpoint. It is read-only and writes no log.
  • stop / start use docker stop / docker start on the project's containers, plus the CKAN set up for the Endpoint. Containers start as they were created, so the port stays (related to Restarting an Endpoint with docker compose loses its port #370).
  • uninstall:
    • asks first, or needs --yes when nobody can answer;
    • removes the containers, the networks, the CKAN containers the installer created, and the .env.backup.* files;
    • keeps the data, .env and the install state, so a re-install brings the Endpoint back with its data;
    • with --remove-data, also removes the volumes, .env and the state;
    • never deletes the checkout, and leaves NetBird with a hint on how to leave it.
  • The install state now records EP_API_PORT, CKAN_DIR and CKAN_CREATED.

Tests

  • New install/tests/test_lifecycle_commands.py: 22 tests, failing on main.
  • Real test with Docker on a laptop:
    • an Endpoint with MongoDB and MinIO was installed, then:
      • status reported it;
      • stop left the port not answering;
      • start brought it back healthy on the same port, with its bucket intact;
      • uninstall kept the volumes, and a re-install came back with the data;
      • uninstall --remove-data left nothing behind;
    • piped status reported two Endpoints installed with 0.34.56 correctly.
    • The tests found a bug, fixed here: the port was looked up by container name and could belong to another checkout's Endpoint. It is now found by project labels.

Release 0.34.63.

@rbardaji
rbardaji merged commit 6bbbaf9 into main Oct 23, 2026
2 checks passed
@rbardaji
rbardaji deleted the feature/372-lifecycle-commands branch October 23, 2026 14:27
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.

Installer: no status/stop/uninstall — upgrade means re-running the script; removal is a manual hunt

1 participant