services: api: build: context: ./docker dockerfile: Dockerfile.php8 ipc: host volumes: - ./:/var/www/html # Don't sync the rhasspy folder # https://stackoverflow.com/a/37898591/903324 - /rhasspy/ # Copy the alsa config from host - "/etc/asound.conf:/etc/asound.conf" command: sh -c "/usr/local/bin/init.sh && exec apache2-foreground" devices: # share the sound device - "/dev/snd:/dev/snd" ports: - "8888:80"