Skip to content

[Feat] Implement snakepipe socket-play/watch based on Unix socket #35

@topheman

Description

@topheman

Currently, we can do:

# mirror terminal
cat /dev/null > /tmp/snakepipe.sock && tail -f /tmp/snakepipe.sock|snakepipe render
# master terminal
snakepipe gamestate|tee /tmp/snakepipe.sock|snakepipe render

Those aren't real unix sockets, it's just a simple file tailed. Lets make an implementation with unix sockets.

Proposition:

  • Master: snakepipe gamestate|snakepipe socket-play|snakepipe render
  • Mirror: snakepipe socket-watch|snakepipe render

Allow overriding the address of the socket (have a default one)

Questions / Constraints

  • How to handle when the mirror terminal is started after the main one (which means it misses the header containing the size of level)
    • use bi-directional socket, so that the mirror can request the header when it starts and the master answers
    • master should support multiple mirrors through one socket

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions