1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
|
# -*- text -*-
##
## templates.conf -- configurations to be used in multiple places
##
## $Id$
######################################################################
#
# Version 2.0 has a useful new feature called "templates".
#
# Use templates by adding a line in radiusd.conf:
#
# $INCLUDE templates.conf
#
# The goal of the templates is to have common configuration located
# in this file, and to list only the *differences* in the individual
# sections. This feature is most useful for sections like "clients"
# or "home_servers", where many may be defined, and each one has
# similar repeated configuration.
#
# Something similar to templates can be done by putting common
# configuration into separate files, and using "$INCLUDE file...",
# but this is more flexible, and simpler to understand. It's also
# cheaper for the server, because "$INCLUDE" makes a copy of the
# configuration for inclusion, and templates are simply referenced.
#
# The templates are defined in the "templates" section, so that they
# do not affect the rest of the server configuration.
#
# A section can reference a template by using "$template name"
#
templates {
#
# The contents of the templates section are other
# configuration sections that would normally go into
# the configuration files.
#
#
# This is a default template for the "home_server" section.
# Note that there is no name for the section.
#
# Any configuration item that is valid for a "home_server"
# section is also valid here. When a "home_server" section
# is defined in proxy.conf, this section is referenced as
# the template.
#
# Configuration items that are explicitly listed in a
# "home_server" section of proxy.conf are used in
# preference to the configuration items listed here.
#
# However, if a configuration item is NOT listed in a
# "home_server" section of proxy.conf, then the value here
# is used.
#
# This functionality lets you put common configuration into
# a template, and to put only the unique configuration
# items in "proxy.conf". Each section in proxy.conf can
# then contain a line "$template home_server", which will
# cause it to reference this template.
#
home_server {
response_window = 20
zombie_period = 40
revive_interval = 120
#
# Etc.
}
#
# You can also have named templates. For example, if you
# are proxying to 3 different home servers all at the same
# site, with identical configurations (other than IP
# addresses), you can use this named template.
#
# Then, each "home_server" section in "proxy.conf" would
# only list the IP address of that home server, and a
# line saying
#
# $template example_com
#
# That would tell FreeRADIUS to look in the section below
# for the rest of the configuration items.
#
# For various reasons, you shouldn't have a "." in the template
# name. Doing so means that the server will be unable to find
# the template.
#
example_com {
type = auth
port = 1812
secret = testing123
response_window = 20
#
# Etc...
}
#
# You can have templates for other sections, too, but they
# seem to be most useful for home_servers.
#
# For now, you can use templates only for sections in
# radiusd.conf, not sub-sections. So you still have to use
# the "$INCLUDE file.." method for things like defining
# multiple "sql" modules, each with similar configuration.
#
}
|