Role Variables

ansible-digital-signage is configured entirely through variables set in your ansible inventory. These can be set per group or per host, just like in any other ansible playbook.

signage_browser

String. Sets which browser will be used to display your configured pages. The role has built-in configurations for chrome, firefox, firefox-esr, and chromium. Currently defaults to chrome. Set this to custom to activate the next couple of variables.

Note

The role uses MOZ_USE_XINPUT2=1 with Firefox to enable proper touchscreen support.

signage_browser_package

String or List. Set this to a valid package name (or names) in your distribution’s repositories, which are necessary to display your signage.

Note

This will be ignored unless signage_browser is set to custom.

signage_browser_command

String. This should be the command, including full path and any arguments, but not the URL or path, to start the browser/application which will display your signage. Examples (which are in use by the role if you select chrome or firefox using signage_browser):

signage_browser_command: "/usr/bin/google-chrome-stable --kiosk"
signage_browser_command: "MOZ_USE_XINPUT2=1 /usr/bin/firefox -kiosk"

Note

This will be ignored unless signage_browser is set to custom.

signage_browser_window_name

String. This should be set to a string which will allow xdotool to find the correct window as implemented in signage-chrome.

signage_orientation

String. Passed to xrandr to set the orientation of the display you’re using. Valid options are normal, inverted, left, and right, per https://x.org/releases/X11R7.5/doc/man/man1/xrandr.1.html. Defaults to normal.

signage_placeholder

String. This is the path to an HTML file which will be displayed in certain circumstances if there is nothing currently on the schedule (for example, on system reboot). Defaults to files/signage-placeholder.html.

signage_reload

Boolean. Enables or disables periodic reloading of the page being displayed. Defaults to True.

signage_reload_every

Sets the interval between automatic reloads. Has no effect if signage_reload is False.

signage_schedule

The Signage Schedule is defined as a list of dictionaries in YAML. Each line in the schedule is formatted as such:

- { days: "Mon,Tue,Wed,Thu,Fri,Sat,Sun", start_time: "08:00", end_time: "17:00", url: "https://example.com" }

The above line will instruct the signage player to display https://example.com from 8:00 in the morning until 5:00 in the afternoon on every weekday. A few notes on this syntax:

  1. The order of these elements doesn’t matter. You can, for example, put the url: directive first. I recommend putting it at the end, in case your url is long enough to make the rest of the schedule hard to read.

  2. Days of the week to display a given URL must be specified as a comma-separated list (with no spaces) of capitalized 3-letter abbreviations.

  3. All times must be specified in 24-hour time.

  4. If there are overlapping times specified in the schedule, the signage player will load the first one it finds.

  5. As long as times don’t overlap, the schedule line shouldn’t have to be in order of start and end time. For your own sanity, however, the author strongly recommends writing the schedule in order.

signage_schedule_location

String. Sets the path to the schedule file which will be automatically generated by the playbook and read by signage-refresh.

Note

I can’t think of a scenario where this would need to be changed. It was easier to make it a variable anyway, though.

signage_startx_command

String. Sets the command which the role will use to start the X11 display server on the signage player. If you don’t know exactly what this is, you don’t need to change it. Default:

signage_startx_command: "xinit -- vt8 -keeptty"

signage_user

String. Sets the username used to actually run the web browser on the signage player. Defaults to signage.

Note

This doesn’t need to be changed in most installations.