# For rpi installs

- name: Set some facts for RPi
  set_fact:
    minetest_server_bin: /library/games/minetest/bin/minetestserver
    minetest_working_dir: /library/games/minetest
# only works if server run as root
    minetest_runas_user: root
    minetest_runas_group: root
  when: is_rpi | bool

# For other installs
- name: Set some facts for other platforms
  set_fact:
    minetest_server_bin: /usr/lib/minetest/minetestserver
    minetest_working_dir: /usr/share/games/minetest
    minetest_runas_user: Debian-minetest
    minetest_runas_group: games
  when: not is_rpi

- name: Set some facts for all
  set_fact:
    minetest_game_dir: "{{ minetest_working_dir }}/games/{{ minetest_default_game }}"
