Gradle and rmi policy files

I want to include a rmi policy file into a java archive (.jar).
My goal is to execute the jar via: java -jar project.jar and it will automatically run with the right policy.

How do I include this rmi policy file into the jar and how do I set an option in the jar that the security policy file for rmi will applied?