The config script does not add quotes around the script invokation, so "health-check script '/config/scripts/myscript 192.0.2.1" is equivalent to just /config/scripts/myscript. Keepalived silently ignored the rest.
Adding quotes around the value string in the template will solve the problem.