]> git.ipfire.org Git - people/stevee/network.git/blame_incremental - src/functions/functions.constants
constants: add new constant NETWORK_SHARE_DIR
[people/stevee/network.git] / src / functions / functions.constants
... / ...
CommitLineData
1#!/bin/bash
2###############################################################################
3# #
4# IPFire.org - A linux based firewall #
5# Copyright (C) 2010 Michael Tremer & Christian Schmidt #
6# #
7# This program is free software: you can redistribute it and/or modify #
8# it under the terms of the GNU General Public License as published by #
9# the Free Software Foundation, either version 3 of the License, or #
10# (at your option) any later version. #
11# #
12# This program is distributed in the hope that it will be useful, #
13# but WITHOUT ANY WARRANTY; without even the implied warranty of #
14# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
15# GNU General Public License for more details. #
16# #
17# You should have received a copy of the GNU General Public License #
18# along with this program. If not, see <http://www.gnu.org/licenses/>. #
19# #
20###############################################################################
21
22# Set gettext text domain.
23TEXTDOMAIN="network"
24
25LOG_DIR=/var/log/network
26RUN_DIR=/run/network
27LOCK_DIR=/var/lock
28
29RED_RUN=${RUN_DIR}/red
30PPP_SECRETS=/etc/ppp/secrets
31
32# Network directory configuration.
33NETWORK_CONFIG_DIR="/etc/network"
34NETWORK_DB_DIR="${RUN_DIR}/db"
35NETWORK_ZONE_DIR="${NETWORK_CONFIG_DIR}"
36NETWORK_HOOKS_DIR=/usr/lib/network/hooks
37NETWORK_TRIGGERS_DIR=/usr/lib/network/triggers
38NETWORK_SHARE_DIR=/usr/share/network
39
40# Network file configuration.
41NETWORK_SETTINGS_FILE=${NETWORK_CONFIG_DIR}/config
42NETWORK_SETTINGS_FILE_PARAMS="DEBUG"
43CONFIG_HOSTNAME="/etc/hostname"
44
45RED_DB_DIR=${RUN_DIR}/red
46ROUTING_DB_DIR=${RUN_DIR}/routing
47
48DB_CONNECTION_FILE="${LOG_DIR}/connections.db"
49
50# (Static) route settings.
51NETWORK_CONFIG_ROUTES="${NETWORK_CONFIG_DIR}/routes"
52NETWORK_CONFIG_ROUTES_PARAMS="network gateway unreachable prohibit blackhole mtu"
53
54# Proper error codes
55EXIT_OK=0
56EXIT_ERROR=1
57EXIT_CONF_ERROR=2
58EXIT_NOT_SUPPORTED=3
59EXIT_NOT_HANDLED=4
60EXIT_COMMAND_NOT_FOUND=127
61EXIT_ERROR_ASSERT=128
62
63EXIT_TRUE=0
64EXIT_FALSE=1
65EXIT_UNKNOWN=2
66
67# Exit codes for IPv6 duplicate address detection (DAD)
68EXIT_DAD_OK=0
69EXIT_DAD_FAILED=8
70EXIT_DAD_TENTATIVE=8
71
72STATUS_UP=0
73STATUS_DOWN=1
74STATUS_NOCARRIER=2
75
76DISCOVER_OK=0
77DISCOVER_ERROR=1
78DISCOVER_NOT_SUPPORTED=2
79
80# The user is able to create zones that begin
81# with these names followed by a number.
82ZONE_LOCAL="net"
83ZONE_NONLOCAL="upl"
84VALID_ZONES="${ZONE_LOCAL} ${ZONE_NONLOCAL}"
85
86SYS_CLASS_NET="/sys/class/net"
87
88# Timeout values
89TIMEOUT_RESTART=2
90
91DEVICE_PRINT_LINE1=" %-24s %s\n"
92
93PORT_PATTERN="pN"
94PORT_PATTERN_ACCESSPOINT="apN"
95PORT_PATTERN_BATMAN_ADV="batN"
96PORT_PATTERN_WIRELESS="wN"
97PORT_PATTERN_WIRELESS_ADHOC="adhocN"
98PORT_PATTERN_WIRELESS_MONITOR="wmonN"