How to setup Nextcloud Talk Recording Backend?

The config (server.conf.in) is only copied for the first time the container is created. If you changed the config afterwards, these changes are not reflected. So remove the container, adjust your server.conf.in and create the container again

For the record, that path is inside the container, not on the host.

I changed the file in-side the container, but still not working. I see it is reading the changes I make now. But it is still not picking up the secret. I do have secret set under [backend1] and [signaling] I turned on debug:

DEBUG:selenium.webdriver.remote.remote_connection:Finished Request
DEBUG:nextcloud.talk.recording.Service-nextcloud.app is for sale! from signaling server
DEBUG:selenium.webdriver.remote.remote_connection:POST http://localhost:52181/session/78608f37-d6b9-48e1-b956-ff2769f33dba/execute/sync {ā€œscriptā€: ā€œ\n OCA.Talk.signalingKill()\n ā€œ, ā€œargsā€: }
DEBUG:urllib3.connectionpool:http://localhost:52181 ā€œPOST /session/78608f37-d6b9-48e1-b956-ff2769f33dba/execute/sync HTTP/1.1ā€ 200 14
DEBUG:selenium.webdriver.remote.remote_connection:Remote response: status=200 | data={ā€œvalueā€:null} | headers=HTTPHeaderDict({ā€˜content-typeā€™: ā€˜application/json; charset=utf-8ā€™, ā€˜cache-controlā€™: ā€˜no-cacheā€™, ā€˜content-lengthā€™: ā€˜14ā€™, ā€˜dateā€™: ā€˜Fri, 14 Apr 2023 07:50:12 GMTā€™})
DEBUG:selenium.webdriver.remote.remote_connection:Finished Request
DEBUG:nextcloud.talk.recording.Service-nextcloud.app is for sale! audio module
DEBUG:nextcloud.talk.recording.Service-nextcloud.app is for sale! display
DEBUG:pyvirtualdisplay.abstractdisplay:stdout=bā€™ā€™
DEBUG:pyvirtualdisplay.abstractdisplay:stderr=bā€™_XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root\nā€™
DEBUG:nextcloud.talk.recording.Service-nextcloud.app is for sale! WebSocket closed
ERROR:nextcloud.talk.recording.Server:Failed to start recording: https://nextcloud.app/ jyooxp6n
Traceback (most recent call last):
File ā€œ/usr/local/lib/python3.8/dist-packages/nextcloud/talk/recording/Server.pyā€, line 170, in _startRecordingService
service.start(actorType, actorId)
File ā€œ/usr/local/lib/python3.8/dist-packages/nextcloud/talk/recording/Service.pyā€, line 195, in start
self._participant.joinCall(self.token)
File ā€œ/usr/local/lib/python3.8/dist-packages/nextcloud/talk/recording/Participant.pyā€, line 458, in joinCall
raise Exception(f"No configured signaling secret for {settings[ā€˜serverā€™]}ā€)
Exception: No configured signaling secret for https://signal.nextcloud.app/standalone-signaling/
DEBUG:selenium.webdriver.remote.remote_connection:DELETE http://localhost:52181/session/78608f37-d6b9-48e1-b956-ff2769f33dba {}
DEBUG:urllib3.connectionpool:http://localhost:52181 ā€œDELETE /session/78608f37-d6b9-48e1-b956-ff2769f33dba HTTP/1.1ā€ 500 105
DEBUG:selenium.webdriver.remote.remote_connection:Remote response: status=500 | data={ā€œvalueā€:{ā€œerrorā€:ā€œunknown errorā€,ā€œmessageā€:ā€œFailed to decode response from marionetteā€,ā€œstacktraceā€:ā€"}} | headers=HTTPHeaderDict({ā€˜content-typeā€™: ā€˜application/json; charset=utf-8ā€™, ā€˜cache-controlā€™: ā€˜no-cacheā€™, ā€˜content-lengthā€™: ā€˜105ā€™, ā€˜dateā€™: ā€˜Fri, 14 Apr 2023 07:50:14 GMTā€™})
DEBUG:selenium.webdriver.remote.remote_connection:Finished Request

I donā€™t think thatā€™s the correct urlā€¦

the nextcloud.app I replaced the real servername. Is the rest of the URL correct?

I do, and all works fine there, but as my screenshot shows, the recording server did not work out for me.

Did you try the recording in a 1:1 or a group call? I think I read something that it only works for group calls currentlyā€¦ But Iā€™m not sure, if this is really the case.

hmā€¦
Well I did create an public call with attendence via link.
Then I attended with 3 different incognito windows :wink:
And I did not find any button record in the talk app.
The settings look valid and the server is running according to the settings.

Any updated docs on how to make this work? So far I havenā€™t been able to get it working.

2 Likes

I also need an update on this xD

Do you have a working server.conf.in? I did add the signaling secret key. I have tried all changes to mine to get it working. Maybe if I could see a working config I can get mine working. Here is from startup of the recording server:

Copying configuration from server.conf.in to /etc/nextcloud-talk-recording/server.conf
Successfully copied 5.63kB to talk-recording:/etc/nextcloud-talk-recording/server.conf
Starting recording backend
No configured backends
No configured signalings
DEBUG:selenium.webdriver.remote.remote_connection:Finished Request
DEBUG:nextcloud.talk.recording.Service-https://nextcloud/-jyooxp6n:Unloading audio module
DEBUG:nextcloud.talk.recording.Service-https://nextcloud/-jyooxp6n:Stopping display
DEBUG:pyvirtualdisplay.abstractdisplay:stdout=bā€™ā€™
DEBUG:pyvirtualdisplay.abstractdisplay:stderr=bā€™_XSERVTransmkdir: ERROR: euid != 0,directory /tmp/.X11-unix will not be created.\nā€™
DEBUG:nextcloud.talk.recording.Service-https://nextcloud/-jyooxp6n.BiDiLogsHelper:BiDi WebSocket closed
ERROR:nextcloud.talk.recording.Server:Failed to start recording: https://nextcloud/ jyooxp6n
Traceback (most recent call last):
File ā€œ/usr/local/lib/python3.8/dist-packages/nextcloud/talk/recording/Server.pyā€, line 170, in _startRecordingService
service.start(actorType, actorId)
File ā€œ/usr/local/lib/python3.8/dist-packages/nextcloud/talk/recording/Service.pyā€, line 195, in start
self._participant.joinCall(self.token)
File ā€œ/usr/local/lib/python3.8/dist-packages/nextcloud/talk/recording/Participant.pyā€, line 458, in joinCall
raise Exception(f"No configured signaling secret for {settings[ā€˜serverā€™]}ā€œ)
Exception: No configured signaling secret for https://signal.nextcloud/standalone-signaling/
DEBUG:selenium.webdriver.remote.remote_connection:DELETE http://localhost:52129/session/d165b137-31b9-43b7-9dde-863e10bc9468 {}
DEBUG:urllib3.connectionpool:http://localhost:52129 ā€œDELETE /session/d165b137-31b9-43b7-9dde-863e10bc9468 HTTP/1.1ā€ 500 105
DEBUG:selenium.webdriver.remote.remote_connection:Remote response: status=500 | data={ā€œvalueā€:{ā€œerrorā€:ā€œunknown errorā€,ā€œmessageā€:ā€œFailed to decode response from marionetteā€,ā€œstacktraceā€:ā€"}} | headers=HTTPHeaderDict({ā€˜content-typeā€™: ā€˜application/json; charset=utf-8ā€™, ā€˜cache-controlā€™: ā€˜no-cacheā€™, ā€˜content-lengthā€™: ā€˜105ā€™, ā€˜dateā€™: ā€˜Thu, 20 Apr 2023 19:06:51 GMTā€™})
DEBUG:selenium.webdriver.remote.remote_connection:Finished Request

I really think that you have a problem with your config fileā€¦

Perhaps you could post your config here replacing the sensitive parts.

And please use the formatting options here :wink: Itā€™s way easier to read if its formatted as a code block.

[logs]
# Log level based on numeric values of Python logging levels:
# - Critical: 50
# - Error:    40
# - Warning:  30
# - Info:     20
# - Debug:    10
# - Not set:   0
level = 10

[http]
# IP and port to listen on for HTTP requests.
listen = 0.0.0.0:8000

[backend]
# Allow any hostname as backend endpoint. This is extremely insecure and should
# only be used during development.
allowall = true

# Common shared secret for requests from and to the backend servers if
# "allowall" is enabled. This must be the same value as configured in the
# Nextcloud admin ui.
secret = safe

# Comma-separated list of backend ids allowed to connect.
#backends = backend-id, another-backend

# If set to "true", certificate validation of backend endpoints will be skipped.
# This should only be enabled during development, e.g. to work with self-signed
# certificates.
# Overridable by backend.
skipverify = true

# Maximum allowed size in bytes for messages sent by the backend.
# Overridable by backend.
#maxmessagesize = 1024

# Width for recorded videos.
# Overridable by backend.
#videowidth = 1920

# Height for recorded videos.
# Overridable by backend.
#videoheight = 1080

# Temporary directory used to store recordings until uploaded. It must be
# writable by the user running the recording server.
# Overridable by backend.
#directory = /tmp

# Backend configurations as defined in the "[backend]" section above. The
# section names must match the ids used in "backends" above.
#[backend-id]
# URL of the Nextcloud instance
#url = https://cloud.domain.invalid

# Shared secret for requests from and to the backend servers. This must be the
# same value as configured in the Nextcloud admin ui.
#secret = the-shared-secret

#[another-backend]
# URL of the Nextcloud instance
#url = https://cloud.otherdomain.invalid

# Shared secret for requests from and to the backend servers. This must be the
# same value as configured in the Nextcloud admin ui.
#secret = the-shared-secret

[signaling]
# Common shared secret for authenticating as an internal client of signaling
# servers if a specific secret is not set for a signaling server. This must be
# the same value as configured in the signaling server configuration file.
#internalsecret = the-shared-secret-for-internal-clients
url = https://signal.nextcloud/standalone-signaling/
secret = safe
# Comma-separated list of signaling servers with specific internal secrets.
#signalings = signaling-id, another-signaling

# Signaling server configurations as defined in the "[signaling]" section above.
# The section names must match the ids used in "signalings" above.
#[signaling-id]
# URL of the signaling server
#url = https://signaling.domain.invalid


# Shared secret for authenticating as an internal client of signaling servers.
# This must be the same value as configured in the signaling server
# configuration file.
#internalsecret = the-shared-secret-for-internal-clients

#[another-signaling]
# URL of the signaling server
#url = https://signaling.otherdomain.invalid

# Shared secret for authenticating as an internal client of signaling servers.
# This must be the same value as configured in the signaling server
# configuration file.
#internalsecret = the-shared-secret-for-internal-clients

[ffmpeg]
# The options given to FFmpeg to encode the audio output. The options given here
# fully override the default options for the audio output.
#outputaudio = -c:a libopus

# The options given to FFmpeg to encode the video output. The options given here
# fully override the default options for the video output.
#outputvideo = -c:v libvpx -deadline:v realtime -crf 10 -b:v 1M

# The extension of the file for audio only recordings.
#extensionaudio = .ogg

# The extension of the file for audio and video recordings.
#extensionvideo = .webm

Your config file clearly doesnā€™t comply to the correct formā€¦ Please adjust your config accordingly and then try again. You have to use the parameter internalsecret instead of secret as in the commented line above your url parameter. Also, the url parameter can only be used within specific signaling parts.

I got it working. Thanks.

Just so other know you must set the signaling server.conf [clients] internalsecret = must match recording server.

3 Likes

So, my problem is not that the recording server does not work as you can see on my screenshot above.
My problem is that the recording button does not appear in my talk ui after applying the backend.

Can anyone tell advise?

Sorry, Iā€™m not running it myself. But you could probably start with posting your config or some relevant log records here. Otherwise we could just guessā€¦

The problem might be with Talk itself, the HPB or the recording server.

There are no errors in the nextcloud logs.
As well as I cannot find any weird errors in the HPB logs.
It seems like all is working and the option for recording just simply does not appear.
If I could click on it somehow or it appears, maybe I would receive an error then.

Can the web server type be the cause for the missing recording button? I have three Nextcloud servers with pretty same configurations, the main difference is that one is with Apache, and the other two are with Nginx. I had no problems setting up the recording backend on the servers with Nginx and the recording button appeared immediately, and the recording button was there even when I mistakenly tried to enter the Signaling URL (not the Recording backend URL) in the recording setup in Talk settings, so it doesnā€™t matter if the Recording backend is configured right and is working, for Talk is enough to receive the Welcome message from the entered URL to start showing the recording button. But the same working configuration applied on the server with Apache doesnā€™t want to show the recording button. I checked several times all corresponding settings and parameters, and all seem correct, all seem working, and no errors, but still no recording button in the menu.

P.S.: We already had such case with a problem caused by differences between Apache and Nginx with the Talk Desktop app. You can find the issue here: