# vim:ff=unix:ts=2:sw=2:ai:expandtab
---
version: '3.5'
services:
  sshd:
    build:
      context: .
    command: ["/usr/sbin/sshd", "-D", "-o", "Port=2222"]
    healthcheck:
      test:
        - CMD-SHELL
        - nc -vzw3 localhost 2222 || exit 1
    hostname: workbench.shore.co.il
    image: registry.shore.co.il/workbench:${TAG:-latest}
    network_mode: host
    restart: always
    tmpfs:
      - /tmp:exec
      - /run
      - /run/lock
    volumes:
      - /dev/kvm:/dev/kvm
      - /etc/group:/etc/group:ro
      - /etc/gshadow:/etc/gshadow:ro
      - /etc/passwd:/etc/passwd:ro
      - /etc/shadow:/etc/shadow:ro
      - /etc/ssh/:/etc/ssh:ro
      - /etc/subgid:/etc/subgid:ro
      - /etc/subuid:/etc/subuid:ro
      - /home:/home
      - /run/dbus:/run/dbus
      - /run/docker.sock:/run/docker.sock
      - /run/user:/run/user
      - /var/lib/flatpak:/var/lib/flatpak
