forked from debezium/container-images
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build-debezium.sh
executable file
·48 lines (42 loc) · 1.23 KB
/
build-debezium.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#!/bin/sh
#
# Parameter 1: image name
# Parameter 2: path to component (if different)
#
build_docker_image () {
IMAGE_NAME=$1;
IMAGE_PATH=$2;
if [ -z "$IMAGE_PATH" ]; then
IMAGE_PATH=${IMAGE_NAME};
fi
echo ""
echo "****************************************************************"
echo "** Building debezium/${IMAGE_NAME}:${DEBEZIUM_VERSION}"
echo "****************************************************************"
docker build -t debezium/${IMAGE_NAME}:${DEBEZIUM_VERSION} ${IMAGE_PATH}/${DEBEZIUM_VERSION}
if [ $? -ne 0 ]; then
exit $?;
fi
}
if [[ -z "$1" ]]; then
echo ""
echo "A version must be specified."
echo ""
echo "Usage: build-debezium <version>";
echo ""
exit 1;
fi
DEBEZIUM_VERSION=$1
build_docker_image zookeeper
build_docker_image kafka
build_docker_image connect-base
build_docker_image connect
build_docker_image example-mysql examples/mysql
build_docker_image example-mysql-gtids examples/mysql-gtids
build_docker_image example-postgres examples/postgres
build_docker_image example-mongodb examples/mongodb
echo ""
echo "**********************************"
echo "Successfully created Docker images"
echo "**********************************"
echo ""