diff --git a/Makefile b/Makefile index b4d181e2e2c..ad3ccfbbbe7 100644 --- a/Makefile +++ b/Makefile @@ -257,6 +257,10 @@ rebuild-ui: build-all-in-one-linux: GOOS=linux $(MAKE) build-all-in-one +.PHONY: build-jaeger-linux +build-jaeger-linux: + GOOS=linux $(MAKE) build-jaeger + # Requires variables: $(BIN_NAME) $(BIN_PATH) $(GO_TAGS) $(DISABLE_OPTIMIZATIONS) $(SUFFIX) $(GOOS) $(GOARCH) $(BUILD_INFO) # Other targets can depend on this one but with a unique suffix to ensure it is always executed. BIN_PATH = ./cmd/$(BIN_NAME) diff --git a/docker-compose/monitor/Makefile b/docker-compose/monitor/Makefile index 1d325829f4a..023ec7ca262 100644 --- a/docker-compose/monitor/Makefile +++ b/docker-compose/monitor/Makefile @@ -14,8 +14,8 @@ build: clean-jaeger # Note: the jaeger "dev" image can be built with "make build". .PHONY: dev dev: export JAEGER_IMAGE_TAG = dev -dev: - docker compose -f docker-compose.yml up +dev: build-v2 + docker compose -f docker-compose-v2.yml up .PHONY: clean-jaeger clean-jaeger: @@ -29,3 +29,15 @@ clean-all: clean-jaeger docker rmi -f otel/opentelemetry-collector-contrib:latest ; \ docker rmi -f prom/prometheus:latest ; \ docker rmi -f grafana/grafana:latest + +.PHONY: build-v2 +build: clean-jaeger + cd ../../ && make build-jaeger-linux + cd ../../ && make create-baseimg PLATFORMS=linux/$(shell go env GOARCH) + cd ../../ && docker buildx build --target release \ + --tag jaegertracing/jaeger:dev \ + --build-arg base_image=localhost:5000/baseimg_alpine:latest \ + --build-arg debug_image=not-used \ + --build-arg TARGETARCH=$(shell go env GOARCH) \ + --load \ + cmd/jaeger diff --git a/docker-compose/monitor/docker-compose-v2.yml b/docker-compose/monitor/docker-compose-v2.yml index 4416b004fa9..91ef24eec78 100644 --- a/docker-compose/monitor/docker-compose-v2.yml +++ b/docker-compose/monitor/docker-compose-v2.yml @@ -4,15 +4,15 @@ services: networks: - backend # TODO: Need to use the local image here while making changes - image: jaegertracing/jaeger + image: jaegertracing/jaeger:${JAEGER_IMAGE_TAG:-latest} volumes: - "./jaeger-ui.json:/etc/jaeger/jaeger-ui.json" # Do we need this for v2 ? Seems to be running without this. - - "./spm-v2.yml:/etc/jaeger/spm-v2.yml" - command: ["--config", "/etc/jaeger/spm-v2.yml"] + - "./jaeger-v2-config.yml:/etc/jaeger/jaeger-v2-config.yml" + command: ["--config", "/etc/jaeger/jaeger-v2-config.yml"] environment: - METRICS_STORAGE_TYPE=prometheus - PROMETHEUS_SERVER_URL=http://prometheus:9090 - - PROMETHEUS_QUERY_SUPPORT_SPANMETRICS_CONNECTOR=${PROMETHEUS_QUERY_SUPPORT_SPANMETRICS_CONNECTOR:-true} + # - PROMETHEUS_QUERY_SUPPORT_SPANMETRICS_CONNECTOR=${PROMETHEUS_QUERY_SUPPORT_SPANMETRICS_CONNECTOR:-true} - PROMETHEUS_QUERY_NAMESPACE=${PROMETHEUS_QUERY_NAMESPACE:-} - PROMETHEUS_QUERY_DURATION_UNIT=${PROMETHEUS_QUERY_DURATION_UNIT:-} - PROMETHEUS_QUERY_NORMALIZE_CALLS=true diff --git a/docker-compose/monitor/spm-v2.yml b/docker-compose/monitor/jaeger-v2-config.yml similarity index 100% rename from docker-compose/monitor/spm-v2.yml rename to docker-compose/monitor/jaeger-v2-config.yml