build: Support JENKINS_JOB

Change from #772