prerequisites 456 B

12345678910111213141516
  1. # Source me
  2. # Check YunoHost version (dnsmasq)
  3. ynh_version=$(sudo dpkg -l yunohost | grep ii | awk '{ print $3 }' | sed 's/\.//g')
  4. if [ "${ynh_version}" -lt 220 ]; then
  5. echo "ERROR: You need a YunoHost version equals or greater than 2.2.0" >&2
  6. exit 1
  7. fi
  8. sudo systemctl is-active dnsmasq &> /dev/null
  9. if [ $? -ne 0 ]; then
  10. echo "ERROR: You need to enable dnsmasq instead of bind9 (apt-get remove bind9 && systemctl start dnsmasq)" >&2
  11. exit 1
  12. fi