Deploy openvidu/openvidu-server-kms:2.20.0 using docker-compose.yml

The environment reports an error after adding the parameter OPENVIDU_RECORDING=true,If you don’t add everything is fine:[ERROR] 2022-05-13 07:43:30,437 [main] io.openvidu.server.recording.service.RecordingManager - Exception connecting to Docker daemon. Code: 709: you need Docker CE installed in this machine to enable OpenVidu recording service. If Docker CE is already installed, make sure to add OpenVidu Server user to “docker” group:
openvidu-server-kms | 1) $ sudo usermod -aG docker $USER
openvidu-server-kms | 2) Log out and log back to the host to reevaluate group membership
openvidu-server-kms | [ERROR] 2022-05-13 07:43:30,437 [main] io.openvidu.server.recording.service.RecordingManager - Error connecting to Docker daemon. Enabling OpenVidu recording module requires Docker. Shutting down OpenVidu Server

and have executed sudo usermod -aG docker $USER,Here is my docker-compose code:
openvidu-server-kms:
image: openvidu/openvidu-server-kms:2.20.0
container_name: openvidu-server-kms
restart: always
privileged: true
ports:
- 4443:4443
volumes:
- /DockerVolumes/openvidu-server/var/run/docker.sock:/var/run/docker.sock
- /DockerVolumes/openvidu-server/record:/opt/openvidu/recordings
environment:
- OPENVIDU_RECORDING_PATH=/opt/openvidu/recordings
- OPENVIDU_RECORDING_PUBLIC_ACCESS=true
- OPENVIDU_RECORDING=true
- DOMAIN_OR_PUBLIC_IP=192.168.0.113
- OPENVIDU_SECRET=MY_SECRET
- KMS_STUN_IP=stun.l.google.com
- KMS_STUN_PORT=19302

Where are you running that? Is it for development purposes?

What is /DockerVolumes?

Try to use:

volumes:
    - /var/run/docker.sock:/var/run/docker.sock

Without the recording volume. The image openvidu-server-kms is for local development environments.

If you are not developping but deploying a real production environments, follow the oficial instructions:

Thank you very much. Have a nice life

1 Like