Build with Gradle
-
Create a new build stage (e.g. for Gradle) and execute the CLI
tasks.register('jcloak', Exec) {mustRunAfter '...'workingDir project.rootDircommandLine 'bash', '-c', "docker run -v ./:/opt/jcloak/bin/files -e LICENSE=<license> jcloak/cli:latest -input ${buildDir}/libs/${project.name}.jar -output ${project.name}-final.jar -includeKey"} -
Edit the
LICENSE
Variable to use your license -
Execute the newly added stage