Changeset 31947


Ignore:
Timestamp:
2012-05-28T17:31:06+02:00 (6 years ago)
Author:
jow
Message:

[packages] ndyndns: use network.sh to find device names

Location:
packages/net/ndyndns
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • packages/net/ndyndns/Makefile

    r29064 r31947  
    11# 
    2 # Copyright (C) 2008-2011 OpenWrt.org 
     2# Copyright (C) 2008-2012 OpenWrt.org 
    33# 
    44# This is free software, licensed under the GNU General Public License v2. 
     
    1010PKG_NAME:=ndyndns 
    1111PKG_VERSION:=2.1 
    12 PKG_RELEASE:=2 
     12PKG_RELEASE:=3 
    1313 
    1414PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz 
  • packages/net/ndyndns/files/ndyndns.init

    r29064 r31947  
    11#!/bin/sh /etc/rc.common 
    2 # Copyright (C) 2007-2011 OpenWrt.org 
     2# Copyright (C) 2007-2012 OpenWrt.org 
    33 
    44START=80 
    55 
    6 include /lib/network 
     6start() { 
     7        . /lib/functions/network.sh 
    78 
    8 start() { 
    9         scan_interfaces 
    10         config_get wan_if 'wan' 'ifname' 
    11         [ -n "$wan_if" ] || return 1 
    129        [ -f /etc/ndyndns/ndyndns.conf ] || { 
    1310                echo "$0: missing config file '/etc/ndyndns/ndyndns.conf'" 1>&2 
    1411                return 1 
    1512        } 
    16         service_start /usr/sbin/ndyndns -c /etc/ndyndns -f /etc/ndyndns/ndyndns.conf -i $wan_if 
     13 
     14        local device 
     15        network_get_device device wan && \ 
     16                service_start /usr/sbin/ndyndns -c /etc/ndyndns -f /etc/ndyndns/ndyndns.conf -i $device 
    1717} 
    1818 
Note: See TracChangeset for help on using the changeset viewer.