Created attachment 265357 [details] git diff www/tomcat* currently, using service(8) command cannot work with tomcat rc script, because $name is not defined. 'service -e' doesn't list /usr/local/etc/rc.d/tomcat110 as enabled when tomcat110_enabled="YES", service -R will restart all local services but tomcat*… I patched the rc script to make it work here, it only lacks support for symlink if main script's name is not enabled, and should not break any existing setup. Another option would require to patch /usr/sbin/service to define name from $file when not properly defined in script, but this could break things elsewhere. Here is the patch I apply to our poudriere setup (and yes, the added ';' is usefull to get /usr/sbin/service's "eval" define name correctly) Hope this helps
Commands like "service tomcat110 restart" work for me - I'm using tomcat on several hosts for ages.
It works for me as well. I am not saying that this is not valid, but I don't understand the problem yet....
the failing ones are using 'service -e' to list enabled services, or 'service -R' to restart all services on the host (without specifying 'tomcat110') It's able to list all pkg services but tomcat110, because it tries to get name of service with "eval `grep ^name= $file`", and $name ends empty
> eval `grep ^name= $file` This is incorrect. Must be something like: name=`basename $file` It's bug in service(8). > name=${name:-tomcat101} This line is "not accepted". The whole point is for the name to be determined dynamically at startup, depending on the name of the rc.d script. The script itself doesn't contain its name in any form.