> Surely a workdir-based env var needs a /state appended, if set and used ?

Thanks for pointing this out.

> Should we be introducing a separate STATEDIR env var ?

According to 95ee02c one is enough... @jimis ?