I am working on a plugin (in lua) for a proprietary program, but would like to make my plugin open source, and require that anyone making derivative works/plugins also do so. This seems like a good case for GPL, but I am unclear if this is valid with a non-free program being effectively dynamically linked which I understand normally means all parts must be GPL. But it also seems like say web-page JavaScript in a proprietary browser sandbox which is OK.
The program itself is not mine, and I do not intend for the two to ever be distributed together.