@alda I actually ended up putting a clause into my terms that states that anything I develop will be open-source and I retain IP ownership, and that the customer just gets a special license for use (which is functionally equivalent to the open-source license anyway, minus a potential attribution requirement).
Surprisingly few customers have objected to this. It's just another contract term to them, apparently.