# https://remote.it can help you remotely maintain an IIAB.

# remoteit_install: True
# remoteit_enabled: False

# All above are set in: github.com/iiab/iiab/blob/master/vars/default_vars.yml
# If nec, change them by editing /etc/iiab/local_vars.yml prior to installing!


# # 2022-03-31: https://remote.it/download/ offered 4 relevant "Device Packages"
# # 1) Raspberry Pi (ARM)    = armhf.rpi
# # 2) Raspberry Pi (ARM64)  = arm64.rpi
# # 3) Debian Linux (ARM64)  = arm64
# # 4) Debian Linux (x86_64) = amd64

# # See https://docs.remote.it/software/device-package/installation to refine URL below:
# device_suffixes:
#   armv6: armhf.rpi
#   armv6l: armhf.rpi
#   armv7: armhf.rpi
#   armv7l: armhf.rpi
#   armv8: arm64.rpi
#   aarch64: arm64
#   x86_64: amd64
# remoteit_device_suffix: "{{ device_suffixes[ansible_architecture] | default('unknown') }}"
# remoteit_device_url: https://downloads.remote.it/remoteit/latest/remoteit.{{ remoteit_device_suffix }}.deb

# # 2022-03-31: Use "latest" above, instead of ever-changing version below
# # remoteit_version: 4.14.1
# # remoteit_deb: remoteit-{{ remoteit_version }}.{{ remoteit_device_suffix }}.deb
# # remoteit_device_url: https://downloads.remote.it/remoteit/v{{ remoteit_version }}/{{ remoteit_deb }}
# # # Example...         https://downloads.remote.it/remoteit/v4.14.1/remoteit-4.14.1.armhf.rpi.deb


# 2022-10-09: https://remote.it/download/ offers 4 relevant "CLI" installs:
# 1) Debian Linux (ARM v6) OR Raspberry Pi (ARM)   = armv6 -> arm-v6
# 2) Debian Linux (ARM v7)                         = armv7 -> arm-v7
# 3) Debian Linux (ARM64)  OR Raspberry Pi (ARM64) = arm64 -> aarch64
# 4) Debian Linux (x86_64)                         = x86_64

# SEE https://www.remote.it/download-list
#     https://www.remote.it/download-list?products=cli to refine arch/URL below
# BUT https://docs.remote.it/software/cli/overview can be useful OR stale :/
remoteit_arch_dict:
  armv6: arm-v6
  armv6l: arm-v6
  armv7: arm-v7
  armv7l: arm-v7
  armv8: aarch64
  aarch64: aarch64
  x86_64: x86_64
remoteit_arch: "{{ remoteit_arch_dict[ansible_machine] | default('unknown') }}"    # A bit safer than ansible_architecture (see kiwix/defaults/main.yml)
remoteit_cli_url: https://downloads.remote.it/cli/latest/remoteit.{{ remoteit_arch }}-linux


# OPTION #1: Run 'sudo iiab-remoteit' after IIAB is installed.

# OPTION #2: Pre-populate your remote.it account "license key" (a.k.a.
# R3_REGISTRATION_CODE) in /etc/iiab/local_vars.yml -- e.g. prior to installing
# IIAB -- by using a line like:
#
# remoteit_license_key: 592AA9BB-XXXX-YYYY-ZZZZ-6E27654C3DF6
#
# BACKGROUND: You can obtain a license key at https://remote.it or by using
# their Desktop Application (https://remote.it/download/) as shown here:
# https://docs.remote.it/oem-and-bulk-provisioning/registration-into-a-users-account#3.-user-receives-the-device-and-registers-his-account
