[Nix] Add easy way to start/stop localstack
Summary:
Allow for services needed to do service integration
tests to be easily started and stopped using nix.
https://linear.app/comm/issue/ENG-1697
Test Plan:
Unfortunately, cannot do a test workflow as we hardcode services
using docker-compose domains (e.g. https://github.com/CommE2E/comm/blob/master/services/blob/src/constants.rs#L5)
To test that the script is running:
nix develop comm-dev services stop # ensure rabbitmq and localstack are stopped pgrep beam.smp # should be empty docker ps | localstack # should be empty comm-dev services start # should emit some rabbitmq info comm-dev services start # should be no-op pgrep beam.smp # should show a PID docker ps | localstack # should show a running container comm-dev services stop # cleanup rabbitmq and localstack pgrep beam.smp # should be empty docker ps | localstack # should be empty
Reviewers: max, varun, atul, bartek
Reviewed By: bartek
Subscribers: ashoat, tomek
Differential Revision: https://phab.comm.dev/D6352