Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Automating the Jenkins build enables an automated application build when changes occur in your source code repository.  When Jenkins detects source code changes, the application is automatically built and scanned using the Hub Black Duck Docker scan client.

Automating the Jenkins build

  1. In Jenkins, click Manage Jenkins > Configure System > Credentials > Global Credentials (Unrestricted) > Add Credentials.
  2. Select:
    1. Kind as Username with Password.
    2. Scope as Global.
    3. Provide your GitHub credentials.
    4. Click OK.



Setting the

...

Black Duck password in the Jenkins environment variable

Add the environment variable BD_HUB_PASSWORD in Manage Jenkins > Configure System > Global properties.

...

  1. Set the GCloud project.
  2. Set the image tag.
  3. Set the Hub Black Duck URL (Hub versions 4.1.0 and higher).
  4. Set the Hub Black Duck scheme.
  5. Build the image for the modified code.
  6. Download the Hub Black Duck Docker scan client, based on your operating system.
  7. Scan the built image using the downloaded Hub Black Duck Docker scan client.
  8. Remove the downloaded Hub Black Duck Docker scan client.
  9. Push the built image to Google cloud.
  10. Remove the local image.

...

After this step, the scans automatically upload to the HubBlack Duck.