Problem to install Arduino IDE on Linux for multi user

Hello,
We use Raspian Buster based PiServer in our classroom. The Pis are booted via PXE and to be able to install software I have to chroot into the OS image.

One piece missing is the Arduino IDE.
Can anyone point me in the right direction on how to install the Arduino IDE for multi user on linux?

I chrooted into the Shell of the Buster image and ran the following:

cd /usr/local/share
mkdir arduino
cd arduino
wget https://downloads.arduino.cc/arduino-nightly-linuxarm.tar.xz
tar xJvf arduino-nightly-linuxarm.tar.xz
arduino-nightly/install.sh

I get the following error:

Adding desktop shortcut, menu item and file associations for Arduino IDE...
/usr/bin/touch: cannot touch '/root/.config/mimeapps.list': No such file or directory
/usr/bin/xdg-mime: 848: /usr/bin/xdg-mime: cannot create /root/.config/mimeapps.list.new: Directory nonexistent
/bin/chown: invalid user: 'pi'

done!