2020-08-06 16:38:53 -07:00
|
|
|
#!/bin/bash
|
2022-04-26 01:29:24 +01:00
|
|
|
set -ex
|
2020-08-06 16:38:53 -07:00
|
|
|
|
2021-09-07 23:06:15 -07:00
|
|
|
MONITORING_COMPOSE=""
|
|
|
|
if [[ $MONITORING == true ]]; then
|
|
|
|
MONITORING_COMPOSE="-f monitoring/docker-compose.monitoring.yml"
|
|
|
|
fi
|
|
|
|
|
|
|
|
CONSUMERS_COMPOSE=""
|
|
|
|
if [[ $SEPARATE_CONSUMERS == true ]]; then
|
|
|
|
CONSUMERS_COMPOSE="-f docker-compose.consumers.yml -f docker-compose.consumers.dev.yml"
|
|
|
|
if [[ $MONITORING == true ]]; then
|
|
|
|
MONITORING_COMPOSE="-f monitoring/docker-compose.monitoring.yml -f monitoring/docker-compose.consumers.monitoring.yml"
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
2022-04-26 01:29:24 +01:00
|
|
|
M1_COMPOSE=""
|
|
|
|
if [[ $(uname -m) == 'arm64' && $(uname) == 'Darwin' ]]; then
|
|
|
|
M1_COMPOSE="-f docker-compose.m1.yml"
|
|
|
|
fi
|
|
|
|
|
2020-08-06 16:38:53 -07:00
|
|
|
# Launches dev instances of DataHub images. See documentation for more details.
|
|
|
|
# YOU MUST BUILD VIA GRADLE BEFORE RUNNING THIS.
|
|
|
|
DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
|
|
|
|
cd $DIR && \
|
2022-09-14 14:26:42 +02:00
|
|
|
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 DOCKER_DEFAULT_PLATFORM="$(uname -m)" docker-compose \
|
2020-08-06 16:38:53 -07:00
|
|
|
-f docker-compose.yml \
|
|
|
|
-f docker-compose.override.yml \
|
|
|
|
-f docker-compose.dev.yml \
|
2022-04-26 01:29:24 +01:00
|
|
|
$CONSUMERS_COMPOSE $MONITORING_COMPOSE $M1_COMPOSE pull \
|
2020-08-06 16:38:53 -07:00
|
|
|
&& \
|
2022-09-14 14:26:42 +02:00
|
|
|
COMPOSE_DOCKER_CLI_BUILD=1 DOCKER_BUILDKIT=1 DOCKER_DEFAULT_PLATFORM="$(uname -m)" docker-compose -p datahub \
|
2020-08-06 16:38:53 -07:00
|
|
|
-f docker-compose.yml \
|
|
|
|
-f docker-compose.override.yml \
|
|
|
|
-f docker-compose.dev.yml \
|
2022-04-26 01:29:24 +01:00
|
|
|
$CONSUMERS_COMPOSE $MONITORING_COMPOSE $M1_COMPOSE up --build $@
|