Skip to content

Commit 5346e2c

Browse files
committed
eclipse-ditto#1699 made building the Ditto UI image optional and configurable in build-images.sh
Signed-off-by: Thomas Jäckle <[email protected]>
1 parent 0777063 commit 5346e2c

File tree

1 file changed

+12
-4
lines changed

1 file changed

+12
-4
lines changed

build-images.sh

+12-4
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,10 @@ SERVICES=(
3939
: "${IMAGE_VERSION:="${SERVICE_VERSION}"}"
4040

4141
print_usage() {
42-
printf "%s [-p HTTP(S) PROXY HOST:PORT]\n" "$1"
42+
printf "%s [-uPh] [-p HTTP(S) PROXY HOST:PORT]\n" "$1"
43+
printf " -u build the ditto-ui as docker image\n" "$1"
44+
printf " -P push the built docker images\n" "$1"
45+
printf " -h display help\n" "$1"
4346
}
4447

4548
print_used_proxies() {
@@ -98,7 +101,9 @@ build_all_docker_images() {
98101
for i in "${SERVICES[@]}"; do
99102
build_docker_image "$i"
100103
done
101-
build_ditto_ui_docker_image
104+
if [[ "$BUILD_UI" == "true" ]]; then
105+
build_ditto_ui_docker_image
106+
fi
102107
}
103108

104109
set_proxies() {
@@ -109,11 +114,14 @@ set_proxies() {
109114
}
110115

111116
evaluate_script_arguments() {
112-
while getopts "p:hP" opt; do
117+
while getopts "p:uhP" opt; do
113118
case ${opt} in
114119
p)
115120
set_proxies "$OPTARG"
116121
;;
122+
u)
123+
BUILD_UI="true"
124+
;;
117125
P)
118126
PUSH_CONTAINERS="true"
119127
;;
@@ -130,6 +138,6 @@ evaluate_script_arguments() {
130138
if [ 0 -eq $# ]; then
131139
print_used_proxies
132140
build_all_docker_images
133-
elif evaluate_script_arguments "$@"; then
141+
elif evaluate_script_arguments $@; then
134142
build_all_docker_images
135143
fi

0 commit comments

Comments
 (0)