Skip to content

Spawing the server in VSCode debugger does not work #16

@pke

Description

@pke

On Windows I am trying to open the server inside a VSCode debugger session and while the server is in the path and is spawned, the output stream handler is called only once with an empty buffer and then the whole node process is terminated.
No other redis server is running at that time.

redis-server 1.2.2

//index.js
const RedisServer = require("redis-server")

// Simply pass the port that you want a Redis server to listen on.
const server = new RedisServer({
  bin: "c:/redis/redis-server.exe",
  port: 5555
});

async function main() {
  await server.open() // <-- this line causes the process to exit
  await server.close()
}

main()

package.json

{
  "name": "redis-server-test",
  "version": "1.0.0",
  "main": "index.js",
  "license": "MIT",
  "dependencies": {
    "redis-server": "1.2.2"
  }
}

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions