Updated the make_fenrir_user.sh script.
This commit is contained in:
parent
bd0aeefc9f
commit
c605b8afbc
@ -6,47 +6,6 @@ if [[ "$(whoami)" != "root" ]]; then
|
|||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
write_pulse() {
|
|
||||||
sudo -u fenrirscreenreader cat << EOF > "/var/fenrirscreenreader/.config/pulse/client.conf"
|
|
||||||
# This file is part of PulseAudio.
|
|
||||||
#
|
|
||||||
# PulseAudio is free software; you can redistribute it and/or modify
|
|
||||||
# it under the terms of the GNU Lesser General Public License as published by
|
|
||||||
# the Free Software Foundation; either version 2 of the License, or
|
|
||||||
# (at your option) any later version.
|
|
||||||
#
|
|
||||||
# PulseAudio is distributed in the hope that it will be useful, but
|
|
||||||
# WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
||||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
||||||
# General Public License for more details.
|
|
||||||
#
|
|
||||||
# You should have received a copy of the GNU Lesser General Public License
|
|
||||||
# along with PulseAudio; if not, see <http://www.gnu.org/licenses/>.
|
|
||||||
|
|
||||||
## Configuration file for PulseAudio clients. See pulse-client.conf(5) for
|
|
||||||
## more information. Default values are commented out. Use either ; or # for
|
|
||||||
## commenting.
|
|
||||||
|
|
||||||
; default-sink =
|
|
||||||
; default-source =
|
|
||||||
default-server = unix:/tmp/pulse.sock
|
|
||||||
; default-dbus-server =
|
|
||||||
|
|
||||||
autospawn = no
|
|
||||||
; autospawn = yes
|
|
||||||
; daemon-binary = /usr/bin/pulseaudio
|
|
||||||
; extra-arguments = --log-target=syslog
|
|
||||||
|
|
||||||
; cookie-file =
|
|
||||||
|
|
||||||
; enable-shm = yes
|
|
||||||
; shm-size-bytes = 0 # setting this 0 will use the system-default, usually 64 MiB
|
|
||||||
|
|
||||||
; auto-connect-localhost = no
|
|
||||||
; auto-connect-display = no
|
|
||||||
EOF
|
|
||||||
}
|
|
||||||
|
|
||||||
# This script checks for, and creates if needed, the fenrirscreenreader user.
|
# This script checks for, and creates if needed, the fenrirscreenreader user.
|
||||||
|
|
||||||
# Find out which group to use for uinput
|
# Find out which group to use for uinput
|
||||||
@ -75,12 +34,8 @@ if ! [[ "$tty" =~ ^[a-zA-Z]+$ ]]; then
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
# Add fenrirscreenreader
|
# Add fenrirscreenreader
|
||||||
id fenrirscreenreader &> /dev/null || {
|
id fenrirscreenreader &> /dev/null || \
|
||||||
useradd -m -d /var/fenrirscreenreader -r -G $input,$tty,$uinput -s /bin/nologin -U fenrirscreenreader;
|
useradd -m -d /var/fenrirscreenreader -r -G $input,$tty,$uinput -s /bin/nologin -U fenrirscreenreader
|
||||||
sleep 1;
|
|
||||||
sudo -u fenrirscreenreader mkdir -p /var/fenrirscreenreader/.config/pulse;
|
|
||||||
write_pulse;
|
|
||||||
}
|
|
||||||
|
|
||||||
#configure directory structure.
|
#configure directory structure.
|
||||||
mkdir -p /var/log/fenrirscreenreader /etc/fenrirscreenreader
|
mkdir -p /var/log/fenrirscreenreader /etc/fenrirscreenreader
|
||||||
@ -95,4 +50,9 @@ for i in /dev/tty[0-9]* ; do
|
|||||||
chmod 660 "$i"
|
chmod 660 "$i"
|
||||||
done
|
done
|
||||||
|
|
||||||
|
sudo -Hu fenrirscreenreader mkdir ~/.config/{pipewire,pulse}
|
||||||
|
echo "Remember to run the configuration script for the sound server you are using as the fenrirscreenreader user."
|
||||||
|
echo "For example, to configure pipewire, run the following:"
|
||||||
|
echo 'sudo -Hu fenrirscreenreader /usr/share/fenrirscreenreader/tools/configure_pipewire.sh'
|
||||||
|
|
||||||
exit 0
|
exit 0
|
||||||
|
Loading…
Reference in New Issue
Block a user