Skip to content

Non-native process managers not stopping processes/services #2586

Description

@tmarkanov

Describe the bug

I'm trying to use alternative process managers (process-compose/mprocs), but they do not stop processes and services on exit. I was able to reproduce this in a minimal example with process-compose while running only the Redis service, but in my project I had the same issue with other services (postgres, rabbitmq), as well as custom processes (e.g. Rails server).

To reproduce

  1. Install latest devenv: nix profile install --accept-flake-config github:cachix/devenv/latest
  2. In an empty dir, run devenv init
  3. Change process manager to process-compose, and enable Redis service (gist)
  4. Enter devenv shell and run devenv up - the Redis service starts normally
  5. Exit process-compose (Ctrl+C)
  6. Observe running processes (e.g. Activity Monitor): the redis-server process does not stop as expected

A similar issue happens if I try to restart the process in process-compose:

Warning: Could not create server TCP listening socket 127.0.0.1:6380: bind: Address already in use                                                                            
Failed listening on port 6380 (tcp), aborting.

I observed similar behaviour when using mprocs, but it does not happen with the native process manager.

Version

devenv 2.0.3+9e5c17c (aarch64-darwin)

Side note
The reason for me wanting to use another process manager is that I would like to be able to use one of my custom processes interactively, which process-compose and mprocs support, theoretically.
Are there any plans to add such functionality to the native process manager in the future?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions