Commit 717a9fe6 authored by Hamza Dely's avatar Hamza Dely
Browse files

MODEL permet d'ajouter la conf d'un modèle particulier de borne

parent c8106a46
......@@ -20,19 +20,20 @@ include $(INCLUDE_DIR)/package.mk
SECRET:=$(shell PYTHONPATH=/etc/crans/secrets/ python -c "import secrets; print secrets.radius_eap_key")
MODEL=
# Pour installer les confs spécifiques, il faut regarder quel est le type de borne ciblé
ifeq ($(CONFIG_TARGET_ar71xx_generic_ESR1750),y)
NETWORKFILE:="network.esr1750"
SYSTEMFILE:="system.esr1750"
else ($(CONFIG_TARGET_ar71xx_generic_UAPPRO),y)
NETWORKFILE:="network.uap_pro"
SYSTEMFILE:="system"
else ($(CONFIG_TARGET_ar71xx_generic_TLWR841),y)
NETWORKFILE:="network.tl_wr841nd"
SYSTEMFILE:="system.tl_wr841nd"
else
NETWORKFILE:="network"
SYSTEMFILE:="system"
MODEL +="esr1750"
endif
ifeq ($(CONFIG_TARGET_ar71xx_generic_UAPPRO),y)
MODEL +="uap_pro"
endif
ifeq ($(CONFIG_TARGET_ar71xx_generic_TLWR841),y)
MODEL +="tl_wr841nd"
endif
ifndef $(MODEL)
MODEL=""
endif
define Package/base-files/conffiles
......@@ -70,8 +71,8 @@ define Package/crans/install
$(INSTALL_DATA) files/etc/monitrc $(1)/etc/monitrc
$(INSTALL_DIR) $(1)/etc/config/
$(INSTALL_DATA) files/etc/config/dhcp $(1)/etc/config/dhcp
$(INSTALL_DATA) files/etc/config/$(NETWORKFILE) $(1)/etc/config/network
$(INSTALL_DATA) files/etc/config/$(SYSTEMFILE) $(1)/etc/config/system
$(INSTALL_DATA) files/etc/config/network.$(MODEL) $(1)/etc/config/network
$(INSTALL_DATA) files/etc/config/system.$(MODEL) $(1)/etc/config/system
$(INSTALL_DATA) files/etc/config/dropbear $(1)/etc/config/dropbear
install -d -m0700 $(1)/etc/dropbear/
$(INSTALL_CONF) files/etc/dropbear/authorized_keys $(1)/etc/dropbear/authorized_keys
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment