Error integrating Jibri with minIO to save recordings

Hi @saghul

I am trying to integrate Jibri with minio to save recordings by following below URL.

I wrote those steps in Dockerfile to create a new Jibri , but the jq command fails with below error.

jq -r “.meeting_url” {RECORDINGS_DIR}/metadata.json | sed -e 's|^[^/]*//||' -e 's|/.*||’ | tr ‘[:upper:]’ ‘[:lower:]’
jq: error: Could not open file /metadata.json: No such file or directory

This is due to the metadata.json doesn’t exist in /config/recrodings/.

Is this how docker form of Jibri expected to work?

Where do I find the file ? Any solutions?

S Krishna

Share your jibri.conf file

@Freddie Thank you for quick response.

I found the metadata.json is not directly under recordings folder in docker.

root@jibri-69fd6858-56sp6:/config/recordings/nevotxlphxmcteka# ls -ltr
total 2152
-rw-r–r-- 1 jibri jibri 2197677 Dec 17 20:36 aa_2020-12-17-20-30-10.mp4
-rw-r–r-- 1 jibri jibri 84 Dec 17 20:36 aa_2020-12-17-20-30-10.json.

It generated random files as metadata file here.

I am using Dockerfile

FROM jitsi/jibri


RUN wget -O /usr/local/bin/mc &&
chmod 755 /usr/local/bin/mc &&
apt-get update &&
apt-get -y install jq

COPY jibri-minio /usr/local/bin/jibri-minio
RUN chmod 755 /usr/local/bin/jibri-minio

S Krishna

You should have a Jibri.conf file in your deployment. In a regular Debian install, the path is /etc/jitsi/jibri/jibri.conf. Not sure if it’s the same path in Docker, but find that file and post the content here.

@Freddie root@jibri-69fd6858-56sp6:/config/recordings/xmdcywyqnjzjeayu# cat /etc/jitsi/jibri/jibri.conf
jibri {

Yeah, your jibri.conf is empty. You need to populate that file. Check out my comment in another post on how to - [SOLVED] Unable to set up recording & streaming features on AWS Ubuntu 20.04

But I dont have problem with recording, only saving to third party storage is not working.

What did you set as finalize script?

Could you paste its codes?

#!/bin/bash -e

Configure Recordings


Configure MinIO


MC_BUCKET=jq -r ".meeting_url" ${RECORDINGS_DIR}/metadata.json | sed -e 's|^[^/]*//||' -e 's|/.*$||' | tr '[:upper:]' '[:lower:]'

Get Recording Information

RECORDINGS_FILE_NAME=find ${RECORDINGS_DIR} -type f -name \*.mp4 | sed -e "s|${RECORDINGS_DIR}/||g" | sed -e "s|.mp4||g"

Upload Recording Files to MinIO


Remove Recording Directory


Set Upload Status to OK


Logs MinIO

echo “------------------------------------------”;
echo “MinIO Host : {MC_ENDPOINT}"; \ echo "MinIO Bucket : {MC_BUCKET}”;
echo “Recording Dir : {RECORDINGS_DIR}"; \ echo "Recording Size : {RECORDINGS_SIZE_HUMAN_READABLE}”;
echo “Upload Status : ${UPLOAD_STATUS}”;
echo “------------------------------------------”;
echo “”;
} >> /var/log/jitsi/jibri/minio.txt

Unset MinIO Host

unset MC_HOST_jibri


exit 0

There are missing $ before some {variable_name}

mv json line seems wrong

Some assignments are wrong (for example RECORDINGS_SIZE_HUMAN_READABLE)

@emrah @Freddie

There are some problem while copy pasting, Here is the screen shot.

You can paste anything you want correctly in textual form by using three (3) backticks, like this ```, at the beginning of a new line

But my problem is still not resolved.

First, test your finalize script alone. Record a meeting without using the finalize script then run your script from the console with the recording folder as an argument and see what will happen. Something like that

/usr/local/bin/your-finalize-script "/tmp/recordings/xsaheiqjjdjsh"

Temporary, disable the folder remove line for the test period. If the script run correctly then use it with Jibri

It works fine when I use default finalize script and it stores in local as well , I think I only need to correct the script to pick the videos correctly and upload.

Hello, did you solve your issue?

yes , it is

I have same issue when upload to minio, can you share the dockerfile?