Skip to content

Commit

Permalink
minor changes in script and dockerfile
Browse files Browse the repository at this point in the history
  • Loading branch information
vijeyash1 committed Sep 15, 2023
1 parent a5d40cb commit e604c5e
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions dockerfiles/migration/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ RUN chmod +x /workspace/script/wait-for-clickhouse.sh
# Use distroless as minimal base image to package the manager binary
# Refer to https://github.com/GoogleContainerTools/distroless for more details
FROM golang:alpine
RUN apk add --no-cache netcat-openbsd
WORKDIR /
COPY --from=builder /workspace/migration .
COPY --from=builder /workspace/sql /sql
Expand Down
2 changes: 1 addition & 1 deletion script/wait-for-clickhouse.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ MAX_RETRIES=60

retry_count=0
while [ $retry_count -lt $MAX_RETRIES ]; do
if clickhouse-client --host $CLICKHOUSE_HOST --port $CLICKHOUSE_PORT --query "SELECT 1"; then
if nc -z -v -w5 $CLICKHOUSE_HOST $CLICKHOUSE_PORT; then
echo "ClickHouse is ready!"
exit 0
else
Expand Down

0 comments on commit e604c5e

Please sign in to comment.