neko/.docker/test
2020-01-27 01:28:39 +00:00

52 lines
1.5 KiB
Bash
Executable File

#!/bin/bash
# usefull debugging tools pavucontrol htop x11vnc
# if [ ! -f ../server/bin/neko ]; then
# echo "build server before testing"
# exit 1
# fi
# if [ ! -d ../client/dist/ ]; then
# echo "build client before testing"
# exit 1
# fi
sudo mkdir -p /var/run/dbus /etc/neko
sudo rm -rf /var/run/dbus.pid
sudo cp files/firefox/neko.js /usr/lib/firefox/mozilla.cfg
sudo cp files/firefox/autoconfig.js /usr/lib/firefox/defaults/pref/autoconfig.js
sudo cp files/firefox/policies.json /usr/lib/firefox/distribution/policies.json
sudo cp files/dbus /usr/bin/dbus
sudo cp files/default.pa /etc/pulse/default.pa
sudo cp files/supervisord.conf /etc/neko/supervisord.conf
sudo cp files/openbox.xml /etc/neko/openbox.xml
if [ ! -f /usr/lib/firefox/distribution/extensions/uBlock0@raymondhill.net.xpi ]; then
sudo mkdir -p /usr/lib/firefox/distribution/extensions
sudo curl -o /usr/lib/firefox/distribution/extensions/uBlock0@raymondhill.net.xpi https://addons.mozilla.org/firefox/downloads/latest/ublock-origin/addon-607454-latest.xpi
fi
sudo cp ../server/bin/neko /usr/bin/neko
sudo cp -R ../client/dist /var/www/
sudo rm -rf $HOME/.mozilla
sudo rm -rf /var/run/supervisord.pid
mkdir -p $HOME/.config/pulse
echo "default-server=unix:/tmp/pulseaudio.socket" > $HOME/.config/pulse/client.conf
export USER=vscode
export SCREEN_WIDTH=1280
export SCREEN_HEIGHT=720
export SCREEN_DEPTH=24
export DISPLAY=:99.0
export NEKO_PASSWORD=neko
export NEKO_BIND=:8080
export NEKO_KEY=
export NEKO_CERT=
supervisord --configuration ./supervisord.conf