Files
upstream-jibri/debian/postinst
upstream-mirror 650a143b63
Some checks failed
Java CI with Maven / Java 17 (push) Failing after 4m40s
Java CI with Maven / Java 21 (push) Failing after 4m41s
snapshot of https://github.com/jitsi/jibri.git @ 3b45602c539ec69d128ea152ae587d0b6582191a (2026-09-15)
2026-09-15 16:13:58 +05:00

51 lines
1.4 KiB
Bash
Executable File

#!/bin/bash
die () {
echo >&2 "$@"
exit 1
}
case "$1" in
configure)
if ! getent group jitsi > /dev/null ; then
groupadd jitsi
fi
if ! getent passwd jibri > /dev/null ; then
echo "Creating jibri user and group"
# Create the Jibri user and group
useradd --system --create-home jibri
echo "Done creating jibri user and group"
usermod -a -G jibri,jitsi,audio,video jibri
echo "jibri user added to audio, video and jibri groups"
fi
# Make the directory for the logs and set the permissions
mkdir -p /var/log/jitsi/jibri
chgrp jitsi /var/log/jitsi/jibri
chmod g+w /var/log/jitsi/jibri
# Move the asoundrc file to the jibri home directory
if [ -f /etc/jitsi/jibri/asoundrc ] ; then
mv /etc/jitsi/jibri/asoundrc /home/jibri/.asoundrc
fi
# Make the directory for the icewm preferences and move the preferences file into it
if [ -f /etc/jitsi/jibri/icewm.preferences ] ; then
mkdir -p /home/jibri/.icewm
mv /etc/jitsi/jibri/icewm.preferences /home/jibri/.icewm/preferences
fi
;;
abort-upgrade|abort-remove|abort-deconfigure)
;;
*)
echo "postinst called with unknown argument \`$1'" >&2
exit 1
;;
esac
exit 0