First, the jdbc drivers must be transferred into the zCX instance. 

Example 8-13 shows how we used sftp to binary-transfer the Db2 JAR files from the USS directory on z/OS into the zCX instance. Before we issued the sftp command, we created the following target path in the ssh container in the zCX instance: home/admin/db2jars 

You run the sftp command from the preceding directory in the zCX instance. 

admin@33825a277992:~$ sftp zcxadm6@wtsc74.pbm.ihost.com:/pp/db2v12/base/d190904/jdbc/classes The authenticity of host 'wtsc74.pbm.ihost.com (129.40.23.1)' can't be established. RSA key fingerprint is SHA256:v27XurOE1iV0hnVzzsL4a3X97F9bH0McumDxFpE3Ogc. Are you sure you want to continue connecting (yes/no)? yes Warning: Permanently added 'wtsc74.pbm.ihost.com,129.40.23.1' (RSA) to the list of known hosts. zcxadm6@wtsc74.pbm.ihost.com's password: Connected to wtsc74.pbm.ihost.com. Changing to: /pp/db2v12/base/d190904/jdbc/classes sftp> get *.jar Fetching /pp/db2v12/base/d190904/jdbc/classes/db2jcc.jar to db2jcc.jar /pp/db2v12/base/d190904/jdbc/classes/db2jcc.jar 100% 3725KB 71.0MB/s 00:00 Fetching /pp/db2v12/base/d190904/jdbc/classes/db2jcc4.jar to db2jcc4.jar /pp/db2v12/base/d190904/jdbc/classes/db2jcc4.jar 100% 4142KB 77.6MB/s 00:00 Fetching /pp/db2v12/base/d190904/jdbc/classes/db2jcc_javax.jar to db2jcc_javax.jar /pp/db2v12/base/d190904/jdbc/classes/db2jcc_javax.jar 100% 23KB 23.2MB/s 00:00 Fetching /pp/db2v12/base/d190904/jdbc/classes/db2jcc_license_cisuz.jar to db2jcc_license_cisuz.jar /pp/db2v12/base/d190904/jdbc/classes/db2jcc_license_cisuz.jar 100% 2755 5.6MB/s 00:00 sftp> quit 

## Prepare the Dockerfile 

Second, you create the Dockerfile to use during the build of the image. Create this file in the /home/admin  directory in the zCX instance and name it dockerfile-base . 

ARG BASE_CONTAINER=s390x/ubuntu FROM $BASE_CONTAINER # Define the label for this image LABEL maintainer="IBM Redbook" # Switch to root user for the following steps USER root # Install all OS dependencies for notebook server that starts but lacks all features. ENV DEBIAN_FRONTEND noninteractive RUN apt-get update && apt-get -yq dist-upgrade \ && apt-get install -yq --no-install-recommends \ wget \ bzip2 \ ca-certificates \ sudo \ locales \ git \ default-jre \ vim \ curl \ fonts-liberation \ 

