Skip to content

Stop / start services quietly when not the focus

Ash McKenzie requested to merge ashmckenzie/use-quiet-when-stopping-services into main

What does this Merge Request do and why?

Now that !2115 (merged) has been merged, this minor MR updates calls to Runit.stop and Runit.start where the output is not relevant and adds quiet: true to not show the output, to reduce noise and improve focus for the various commands. For example:

Before

$ gdk reset-praefect-data
⚠️  WARNING: We're about to remove Praefect PostgreSQL data.
Are you sure? [y/N]: y
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/gitlab-workhorse: 2475s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/rails-background-jobs: 2475s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/rails-web: 2475s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/sshd: 2475s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/webpack: 2475s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/minio: 2475s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/praefect: 1s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/praefect-gitaly-0: 1s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/redis: 0s
ok: down: /Users/ash/src/gitlab/gitlab-development-kit/services/postgresql: 1s
ok: run: /Users/ash/src/gitlab/gitlab-development-kit/services/postgresql: (pid 77371) 0s, normally down
DROP DATABASE
CREATE DATABASE
praefect sql-migrate: OK (applied 24 migrations)

After

$ gdk reset-praefect-data
⚠️  WARNING: We're about to remove Praefect PostgreSQL data.
Are you sure? [y/N]: y
DROP DATABASE
CREATE DATABASE
praefect sql-migrate: OK (applied 24 migrations)

Merge Request checklist

  • This change is backward compatible. If not, please include steps to communicate to our users.
  • Tests added for new functionality. If not, please raise Issue to follow-up.
  • Documentation added/updated, if needed.
  • gdk doctor test added, if needed.
  • Add the ~highlight label if this MR should be included in the CHANGELOG.md.
Edited by Ash McKenzie

Merge request reports