Project

General

Profile

Download (2.48 KB) Statistics
| Branch: | Tag: | Revision:
1
#!/bin/sh
2
#
3
# rc.gateway_alarm
4
#
5
# Copyright (c) 2015 Electric Sheep Fencing, LLC. All rights reserved.
6
#
7
# Redistribution and use in source and binary forms, with or without
8
# modification, are permitted provided that the following conditions are met:
9
#
10
# 1. Redistributions of source code must retain the above copyright notice,
11
#    this list of conditions and the following disclaimer.
12
#
13
# 2. Redistributions in binary form must reproduce the above copyright
14
#    notice, this list of conditions and the following disclaimer in
15
#    the documentation and/or other materials provided with the
16
#    distribution.
17
#
18
# 3. All advertising materials mentioning features or use of this software
19
#    must display the following acknowledgment:
20
#    "This product includes software developed by the pfSense Project
21
#    for use in the pfSense® software distribution. (http://www.pfsense.org/).
22
#
23
# 4. The names "pfSense" and "pfSense Project" must not be used to
24
#    endorse or promote products derived from this software without
25
#    prior written permission. For written permission, please contact
26
#    coreteam@pfsense.org.
27
#
28
# 5. Products derived from this software may not be called "pfSense"
29
#    nor may "pfSense" appear in their names without prior written
30
#    permission of the Electric Sheep Fencing, LLC.
31
#
32
# 6. Redistributions of any form whatsoever must retain the following
33
#    acknowledgment:
34
#
35
# "This product includes software developed by the pfSense Project
36
# for use in the pfSense software distribution (http://www.pfsense.org/).
37
#
38
# THIS SOFTWARE IS PROVIDED BY THE pfSense PROJECT ``AS IS'' AND ANY
39
# EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
40
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
41
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE pfSense PROJECT OR
42
# ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
43
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
44
# NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
45
# LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
46
# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,
47
# STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
48
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
49
# OF THE POSSIBILITY OF SUCH DAMAGE.
50

    
51
GW="$1"
52

    
53
if [ -z "$GW" ]; then
54
	exit 1
55
fi
56

    
57
/usr/local/sbin/pfSctl \
58
	-c "service reload dyndns ${GW}" \
59
	-c "service reload ipsecdns" \
60
	-c "service reload openvpn ${GW}" \
61
	-c "filter reload" >/dev/null 2>&1
62

    
63
exit $?
(52-52/102)