I stole the initialisation code from [the old SPMA script](https://github.com/quattor/spma/blob/master/src/main/scripts/spma#L428).  I will update.

Actually, have I put `spma-run` in the right place?  It's a script that will need to be deployed to `/usr/bin`, it is not an NCM component.  It is, however, used by the NCM component (if `/software/components/spma/run` is `yes`), or may be run by the user or by an external process.