Skip to content
Snippets Groups Projects
Commit 3d3d38b7 authored by David Hoese's avatar David Hoese
Browse files

Merge branch 'feature-lobby-startup-script' into 'develop'

Add lobby-rig startup scripts and README

See merge request !16
parents d519300b f964fb21
No related branches found
No related tags found
1 merge request!16Add lobby-rig startup scripts and README
Pipeline #9839 passed
# SSEC Lobby Display
The scripts and other files in this directory are used to configure the
displays in the lobby of the AOSS building.
## Mini-dashboard
In the lobby there is a small monitor to the left after entering that displays
a real-time display of data from the AOSS Tower instrument. This display shows
a fullscreen Firefox window showing:
https://metobs.ssec.wisc.edu/aoss/tower/lobby
This page is designed after the legacy Java application by Tom Whittaker. To
burn-in on the monitor the display will go black at certain times of the day.
A version that does not go black is at https://metobs.ssec.wisc.edu/aoss/tower/lobby24-7.
The display is also configured to not start any screensavers or other
power-saving techniques to keep it showing the dashboard.
The system driving the monitor is called `lobby-rig`. It is currently a CentOS
system with Gnome desktop environment. The machine is configured to auto-login
to the `tomw` user account (this may be changed in the future). Various scripts
are placed in `/home/tomw/.config/autostart` and `/home/tomw` in order to get
the Firefox window displayed and other configurations set on startup. These
files are in the `https://gitlab.ssec.wisc.edu/metobs/MetObs` Git repository
in the `lobby_scripts` directory and are described below:
* `lobby.desktop`: Placed in the autostart directory, this initializes the
dashboard by calling the `startup.sh` script.
* `startup.sh`: Placed in the home directory, this starts Firefox pointed to
the lobby web page. It also uses the `xdotool` to make Firefox fullscreen
and refresh the page after it is fullscreen. This refresh is a workaround
for font sizing issue and can be removed in the future. Currently the
version of `xdotool` that comes with CentOS6 has bugs which cause these
`xdotool` commands to not do anything. As a workaround the "Auto Fullscreen"
Firefox extension was installed. After the machine is upgraded to a newer
CentOS this shouldn't be needed anymore (hopefully).
* `noscreensaver.desktop`: This runs `xset.sh` at startup.
* `xset.sh`: This script sets various settings to make sure a screensaver is
is never started.
## Weather Underground Data Upload
In the past the `lobby-rig` machine was also responsible for uploading
realtime data to the Weather Underground service (https://wunderground.com).
This was done by Java code and used the legacy RAIN API. This is now handled
by the AOSS Tower InfluxDB ingest scripts.
# Copy this file to `/home/tomw/.config/autostart/`
[Desktop Entry]
Type=Application
Exec=/home/tomw/startup.sh
Hidden=false
X-GNOME-Autostart-enabled=true
Name[en_US]=lobby rig
Name=lobby rig
Comment[en_US]=
Comment=
\ No newline at end of file
# Copy this file to `/home/tomw/.config/autostart/`
[Desktop Entry]
Type=Application
Exec=sh /home/tomw/xset.sh
Hidden=false
X-GNOME-Autostart-enabled=true
Name[en_US]=screensaver disable
Name=screensaver disable
Comment[en_US]=disables dpms and xscreensaver
Comment=disables dpms and xscreensaver
\ No newline at end of file
#!/usr/bin/env bash
# Source: https://gitlab.ssec.wisc.edu/metobs/MetObsSite
#xset -dpms s off
firefox -url https://metobs.ssec.wisc.edu/aoss/tower/lobby &
firefox_pid=$!
sleep 45
# These should be used on CentOS 7+ but the version of xdotool that comes
# with CentOS 6 is too old and buggy it seems.
# Resorted to "Auto Fullscreen" Firefox extension:
# https://addons.mozilla.org/en-US/firefox/addon/autofullscreen/
xdotool search --onlyvisible --desktop 0 --class "Firefox" windowactivate key F11
# force refresh until webpage text auto-updates when window size changes
xdotool search --onlyvisible --desktop 0 --class "Firefox" windowactivate key F5
# wait on firefox
wait $!
\ No newline at end of file
#!/usr/bin/env bash
xset -dpms
xset s off
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment