mirror of
https://github.com/home-assistant/core.git
synced 2025-12-03 06:28:19 +00:00
13 lines
320 B
Python
13 lines
320 B
Python
"""Go2rtc utility functions."""
|
|
|
|
from pathlib import Path
|
|
|
|
_HA_MANAGED_UNIX_SOCKET_FILE = "go2rtc.sock"
|
|
|
|
|
|
def get_go2rtc_unix_socket_path(path: str | Path) -> str:
|
|
"""Get the Go2rtc unix socket path."""
|
|
if not isinstance(path, Path):
|
|
path = Path(path)
|
|
return str(path / _HA_MANAGED_UNIX_SOCKET_FILE)
|