From 26a4573ff244a06da7870ed6ba9a55208a4d9ee2 Mon Sep 17 00:00:00 2001 From: Bob Roldan Date: Fri, 21 Oct 2022 18:12:50 -0400 Subject: [PATCH] DBZ-5757 Updates downstream steps to build KC custom container images --- .../modules/ROOT/pages/connectors/db2.adoc | 26 +++++++++++++++--- .../ROOT/pages/connectors/mongodb.adoc | 26 +++++++++++++++--- .../modules/ROOT/pages/connectors/mysql.adoc | 26 +++++++++++++++--- .../modules/ROOT/pages/connectors/oracle.adoc | 27 +++++++++++++++---- .../ROOT/pages/connectors/postgresql.adoc | 27 ++++++++++++++++--- .../ROOT/pages/connectors/sqlserver.adoc | 26 +++++++++++++++--- 6 files changed, 133 insertions(+), 25 deletions(-) diff --git a/documentation/modules/ROOT/pages/connectors/db2.adoc b/documentation/modules/ROOT/pages/connectors/db2.adoc index f6414a875..c8ec1ba30 100644 --- a/documentation/modules/ROOT/pages/connectors/db2.adoc +++ b/documentation/modules/ROOT/pages/connectors/db2.adoc @@ -1729,19 +1729,37 @@ For more information, see link:{LinkDeployStreamsOpenShift}[{NameDeployStreamsOp .. Create a Dockerfile that uses `{DockerKafkaConnect}` as the base image. For example, from a terminal window, enter the following command: + +===================================================================== + [source,shell,subs="+attributes,+quotes"] ---- cat <debezium-container-for-db2.yaml // <1> FROM {DockerKafkaConnect} USER root:root RUN mkdir -p /opt/kafka/plugins/debezium // <2> -RUN curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip -RUN curl -O https://repo1.maven.org/maven2/com/ibm/db2/jcc/{db2-version}/jcc-{db2-version}.jar +RUN cd /opt/kafka/plugins/debezium/ \ +&& curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& unzip debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& rm debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ \ +&& curl -O https://repo1.maven.org/maven2/com/ibm/db2/jcc/{db2-version}/jcc-{db2-version}.jar USER 1001 EOF ---- -<1> You can specify any file name that you want. -<2> Specifies the path to your Kafka Connect plug-ins directory. If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. +===================================================================== ++ +[cols="1,7",options="header"] +|=== +|Item |Description + +|1 +|You can specify any file name that you want. + +|2 +|Specifies the path to your Kafka Connect plug-ins directory. +If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. + +|=== + The command creates a Dockerfile with the name `debezium-container-for-db2.yaml` in the current directory. diff --git a/documentation/modules/ROOT/pages/connectors/mongodb.adoc b/documentation/modules/ROOT/pages/connectors/mongodb.adoc index be3ffcf2f..28f58d47a 100644 --- a/documentation/modules/ROOT/pages/connectors/mongodb.adoc +++ b/documentation/modules/ROOT/pages/connectors/mongodb.adoc @@ -1056,18 +1056,36 @@ You then create two custom resources (CRs): .. Create a Dockerfile that uses `{DockerKafkaConnect}` as the base image. For example, from a terminal window, enter the following command: + +===================================================================== + [source,shell,subs="+attributes,+quotes"] ---- -cat <debezium-container-for-mongodb.yaml // <1> +cat <debezium-container-for-{context}.yaml // <1> FROM {DockerKafkaConnect} USER root:root RUN mkdir -p /opt/kafka/plugins/debezium // <2> -RUN curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ \ +&& curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& unzip debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& rm debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ USER 1001 EOF ---- -<1> You can specify any file name that you want. -<2> Specifies the path to your Kafka Connect plug-ins directory. If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. +===================================================================== ++ +[cols="1,7",options="header"] +|=== +|Item |Description + +|1 +|You can specify any file name that you want. + +|2 +|Specifies the path to your Kafka Connect plug-ins directory. +If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. + +|=== + The command creates a Dockerfile with the name `debezium-container-for-mongodb.yaml` in the current directory. diff --git a/documentation/modules/ROOT/pages/connectors/mysql.adoc b/documentation/modules/ROOT/pages/connectors/mysql.adoc index 8f5759e38..b17430af8 100644 --- a/documentation/modules/ROOT/pages/connectors/mysql.adoc +++ b/documentation/modules/ROOT/pages/connectors/mysql.adoc @@ -2249,18 +2249,36 @@ For more information, see link:{LinkDeployStreamsOpenShift}[{NameDeployStreamsOp .. Create a Dockerfile that uses `{DockerKafkaConnect}` as the base image. For example, from a terminal window, enter the following command: + +===================================================================== + [source,shell,subs="+attributes,+quotes"] ---- -cat <debezium-container-for-mysql.yaml // <1> +cat <debezium-container-for-{context}.yaml // <1> FROM {DockerKafkaConnect} USER root:root RUN mkdir -p /opt/kafka/plugins/debezium // <2> -RUN curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ \ +&& curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& unzip debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& rm debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ USER 1001 EOF ---- -<1> You can specify any file name that you want. -<2> Specifies the path to your Kafka Connect plug-ins directory. If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. +===================================================================== ++ +[cols="1,7",options="header"] +|=== +|Item |Description + +|1 +|You can specify any file name that you want. + +|2 +|Specifies the path to your Kafka Connect plug-ins directory. +If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. + +|=== + The command creates a Dockerfile with the name `debezium-container-for-mysql.yaml` in the current directory. diff --git a/documentation/modules/ROOT/pages/connectors/oracle.adoc b/documentation/modules/ROOT/pages/connectors/oracle.adoc index 99db56b05..6fdd83931 100644 --- a/documentation/modules/ROOT/pages/connectors/oracle.adoc +++ b/documentation/modules/ROOT/pages/connectors/oracle.adoc @@ -2118,20 +2118,37 @@ For more information, see xref:{link-oracle-connector}#obtaining-the-oracle-jdbc .. Create a Dockerfile that uses `{DockerKafkaConnect}` as the base image. For example, from a terminal window, enter the following command: + +===================================================================== + [source,shell,subs="+attributes,+quotes"] ---- -cat <debezium-container-for-oracle.yaml // <1> +cat <debezium-container-for-{context}.yaml // <1> FROM {DockerKafkaConnect} USER root:root RUN mkdir -p /opt/kafka/plugins/debezium // <2> -RUN curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip -RUN curl -O https://repo1.maven.org/maven2/com/oracle/ojdbc/ojdbc8/{ojdbc8-version}/ojdbc8-{ojdbc8-version}.jar +RUN cd /opt/kafka/plugins/debezium/ \ +&& curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& unzip debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& rm debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ \ +&& curl -O https://repo1.maven.org/maven2/com/oracle/ojdbc/ojdbc8/21.1.0.0/ojdbc8-21.1.0.0.jar USER 1001 EOF ---- -<1> You can specify any file name that you want. -<2> Specifies the path to your Kafka Connect plug-ins directory. If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. +===================================================================== + +[cols="1,7",options="header"] +|=== +|Item |Description + +|1 +|You can specify any file name that you want. + +|2 +|Specifies the path to your Kafka Connect plug-ins directory. +If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. + +|=== The command creates a Dockerfile with the name `debezium-container-for-oracle.yaml` in the current directory. .. Build the container image from the `debezium-container-for-oracle.yaml` Docker file that you created in the previous step. diff --git a/documentation/modules/ROOT/pages/connectors/postgresql.adoc b/documentation/modules/ROOT/pages/connectors/postgresql.adoc index 0d194ea35..fe379da41 100644 --- a/documentation/modules/ROOT/pages/connectors/postgresql.adoc +++ b/documentation/modules/ROOT/pages/connectors/postgresql.adoc @@ -2354,17 +2354,36 @@ Apply this CR to the same OpenShift instance where you applied the `KafkaConnect .. Create a Dockerfile that uses `{DockerKafkaConnect}` as the base image. For example, from a terminal window, enter the following command: + +===================================================================== + [source,shell,subs="+attributes,+quotes"] ---- -cat <debezium-container-for-postgresql.yaml // <1> +cat <debezium-container-for-{context}.yaml // <1> FROM {DockerKafkaConnect} USER root:root RUN mkdir -p /opt/kafka/plugins/debezium // <2> -RUN curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zipUSER 1001 +RUN cd /opt/kafka/plugins/debezium/ \ +&& curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& unzip debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& rm debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ +USER 1001 EOF ---- -<1> You can specify any file name that you want. -<2> Specifies the path to your Kafka Connect plug-ins directory. If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. +===================================================================== ++ +[cols="1,7",options="header"] +|=== +|Item |Description + +|1 +|You can specify any file name that you want. + +|2 +|Specifies the path to your Kafka Connect plug-ins directory. +If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. + +|=== + The command creates a Dockerfile with the name `debezium-container-for-postgresql.yaml` in the current directory. diff --git a/documentation/modules/ROOT/pages/connectors/sqlserver.adoc b/documentation/modules/ROOT/pages/connectors/sqlserver.adoc index 1438cafca..2d0a4eee4 100644 --- a/documentation/modules/ROOT/pages/connectors/sqlserver.adoc +++ b/documentation/modules/ROOT/pages/connectors/sqlserver.adoc @@ -1808,18 +1808,36 @@ You then need to create the following custom resources (CRs): .. Create a Dockerfile that uses `{DockerKafkaConnect}` as the base image. For example, from a terminal window, enter the following command: + +===================================================================== + [source,shell,subs="+attributes,+quotes"] ---- -cat <debezium-container-for-sqlserver.yaml // <1> +cat <debezium-container-for-{context}.yaml // <1> FROM {DockerKafkaConnect} USER root:root RUN mkdir -p /opt/kafka/plugins/debezium // <2> -RUN curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ \ +&& curl -O {red-hat-maven-repository}debezium/debezium-connector-{connector-file}/{debezium-version}-redhat-____/debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& unzip debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip \ +&& rm debezium-connector-{connector-file}-{debezium-version}-redhat-____-plugin.zip +RUN cd /opt/kafka/plugins/debezium/ USER 1001 EOF ---- -<1> You can specify any file name that you want. -<2> Specifies the path to your Kafka Connect plug-ins directory. If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. +===================================================================== ++ +[cols="1,7",options="header"] +|=== +|Item |Description + +|1 +|You can specify any file name that you want. + +|2 +|Specifies the path to your Kafka Connect plug-ins directory. +If your Kafka Connect plug-ins directory is in a different location, replace this path with the actual path of your directory. + +|=== + The command creates a Dockerfile with the name `debezium-container-for-sqlserver.yaml` in the current directory.