#!/bin/sh [ -f /etc/lime_release ] && . /etc/lime_release || { echo "LibreMesh version not found in /etc/lime_release - skipping" exit 0 } feeds_file="/etc/opkg/limefeeds.conf" [ -f "$feeds_file" ] && { echo "LibreMesh opkg feeds already defined - skipping" exit 0 } [ "$LIME_CODENAME" == "development" ] && { packages_url="http://feed.libremesh.org/master"; } || { packages_url="http://feed.libremesh.org/$LIME_RELEASE" } profiles_url="http://feed.libremesh.org/profiles" key_name="a71b3c8285abd28b" key_content="RWSnGzyChavSiyQ+vLk3x7F0NqcLa4kKyXCdriThMhO78ldHgxGljM/8" echo "Configuring official LibreMesh opkg feeds" echo "src/gz libremesh $packages_url" > "$feeds_file" echo "src/gz profiles $profiles_url" >> "$feeds_file" echo "untrusted comment: signed by libremesh.org key $key_name" > "/etc/opkg/keys/$key_name" echo "$key_content" >> "/etc/opkg/keys/$key_name"