Retrieve and generate debian package of Oracle JDK

I have written script for retrieving Oracle JDK tarball automatically, why I wanted to retrieve and make debian package with make-jpkg command on Jenkins.

  1. Retrieve JDK 7 and JDK 8 download page urls from Oracle JDK Download site.

  2. Retrieve JDK tarball URL.

  3. Check the save file local directory.

  4. Download with “wget” command.

Requirements

  • python-requests

  • python-query

  • wget

  • java-package

Prepare as following script for Jenkins.

#!/bin/sh

python retrieve_jdk.py -j $1
echo -e '\n\n' | make-jpkg $(ls -1 jdk-*-linux-x64.tar.gz | tail -1)

See also