Hi guys, I am trying to create the following config file, per "apn" and have it $included as config files to load on start :- -- snip -- apn = imobile realm "${apn}" { acct_pool = pool."${apn}" } (line 7)home_server_pool pool."${apn}" { type = load-balance home_server = home1.example.com virtual_server = virtual."${apn}" } I'd like to define a variable called "apn" and have it referenced elsewhere in the config file. I am getting this error upon start-up though:- Error: /etc/freeradius/3.0/proxy-conf/imobile[7]: Parse error after "apn": unexpected token "}" I have tried several ways of writing the variable on line 7 - with quotes, without quotes, single quotes, etc. but I can't get it working.. Thanks, Gabriel
On Jun 5, 2019, at 4:58 AM, Gabriel Marais <gabriel.j.marais@gmail.com> wrote:
Hi guys,
I am trying to create the following config file, per "apn" and have it $included as config files to load on start :-
-- snip -- apn = imobile
realm "${apn}" { acct_pool = pool."${apn}"
In short, you can't just invent new syntax and expect it to work. The configuration files don't auto-append simple text and double-quoted strings to get a "new" value. You just can't do what you're trying to do. I suggest using an external templating system. Akan DeKok.
participants (2)
-
Alan DeKok -
Gabriel Marais