Skip to content

Commit 1bf386c

Browse files
committed
address some review comments
Signed-off-by: Lionel Villard <[email protected]>
1 parent 1ce1162 commit 1bf386c

File tree

3 files changed

+13
-31
lines changed

3 files changed

+13
-31
lines changed

Makefile

Lines changed: 11 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,11 @@ SIDECAR_IMAGE_TAG_BASE ?= $(IMAGE_REGISTRY)/$(SIDECAR_IMAGE_NAME)
1818
SIDECAR_IMG = $(SIDECAR_IMAGE_TAG_BASE):$(SIDECAR_TAG)
1919
NAMESPACE ?= hc4ai-operator
2020

21-
ACTIVATOR_IMAGE_TAG_BASE ?= $(IMAGE_REGISTRY)/$(PROJECT_NAME)-activator
22-
ACTIVATOR_IMG = $(ACTIVATOR_IMAGE_TAG_BASE):$(EPP_TAG)
21+
ACTIVATOR_IMAGE_NAME ?= llm-d-activator
22+
ACTIVATOR_NAME ?= activator
23+
ACTIVATOR_TAG ?= dev
24+
ACTIVATOR_IMAGE_TAG_BASE ?= $(IMAGE_REGISTRY)/$(ACTIVATOR_IMAGE_NAME)
25+
ACTIVATOR_IMG = $(ACTIVATOR_IMAGE_TAG_BASE):$(ACTIVATOR_TAG)
2326

2427
# Map go arch to typos arch
2528
ifeq ($(TARGETARCH),amd64)
@@ -57,10 +60,13 @@ SRC = $(shell find . -type f -name '*.go')
5760
# Internal variables for generic targets
5861
epp_IMAGE = $(IMG)
5962
sidecar_IMAGE = $(SIDECAR_IMG)
63+
activator_IMAGE = $(ACTIVATOR_IMG)
6064
epp_NAME = epp
6165
sidecar_NAME = $(SIDECAR_NAME)
66+
activator_NAME = $(ACTIVATOR_NAME)
6267
epp_LDFLAGS = -ldflags="$(LDFLAGS)"
6368
sidecar_LDFLAGS =
69+
activator_LDFLAGS = -ldflags="$(LDFLAGS)"
6470
epp_TEST_FILES = go list ./... | grep -v /test/ | grep -v ./pkg/sidecar/
6571
sidecar_TEST_FILES = go list ./pkg/sidecar/...
6672

@@ -133,25 +139,17 @@ lint: check-golangci-lint check-typos ## Run lint
133139
##@ Build
134140

135141
.PHONY: build
136-
build: epp-build sidecar-build ## Build the project
142+
build: epp-build sidecar-build activator-build ## Build the project
137143

138144
.PHONY: %-build
139145
%-build: check-go install-dependencies download-tokenizer ## Build the project
140146
@printf "\033[33;1m==== Building ====\033[0m\n"
141147
go build $($*_LDFLAGS) -o bin/$($*_NAME) cmd/$($*_NAME)/main.go
142148

143-
##@ Build Activator
144-
145-
.PHONY: activator-build
146-
activator-build: check-go install-dependencies download-tokenizer ## Build the project
147-
@printf "\033[33;1m==== Building ====\033[0m\n"
148-
go build -ldflags="$(LDFLAGS)" -o bin/activator cmd/activator/main.go
149-
150-
151149
##@ Container Build/Push
152150

153151
.PHONY: image-build
154-
image-build: epp-image-build sidecar-image-build ## Build Docker image
152+
image-build: epp-image-build sidecar-image-build activator-image-build ## Build Docker image
155153

156154
.PHONY: %-image-build
157155
%-image-build: check-container-tool ## Build Docker image ## Build Docker image using $(CONTAINER_TOOL)
@@ -165,29 +163,13 @@ image-build: epp-image-build sidecar-image-build ## Build Docker image
165163
-t $($*_IMAGE) -f Dockerfile.$* .
166164

167165
.PHONY: image-push
168-
image-push: epp-image-push sidecar-image-push ## Push Docker images to registry
166+
image-push: epp-image-push sidecar-image-push activator-image-push ## Push Docker images to registry
169167

170168
.PHONY: %-image-push
171169
%-image-push: check-container-tool load-version-json ## Push Docker image to registry
172170
@printf "\033[33;1m==== Pushing Docker image $($*_IMAGE) ====\033[0m\n"
173171
$(CONTAINER_TOOL) push $($*_IMAGE)
174172

175-
.PHONY: activator-image-build
176-
activator-image-build: ## Build the activator image using Docker Buildx.
177-
$(CONTAINER_TOOL) build \
178-
--platform linux/$(TARGETARCH) \
179-
--build-arg TARGETOS=linux \
180-
--build-arg TARGETARCH=${TARGETARCH} \
181-
--build-arg COMMIT_SHA=${GIT_COMMIT_SHA} \
182-
--build-arg BUILD_REF=${BUILD_REF} \
183-
-t $(ACTIVATOR_IMG) \
184-
-f Dockerfile.activator .
185-
186-
.PHONY: activator-image-push
187-
activator-image-push: check-container-tool load-version-json ## Push Activator Docker image $(ACTIVATOR_IMG) to registry
188-
@printf "\033[33;1m==== Pushing Activator Docker image $(ACTIVATOR_IMG) ====\033[0m\n"
189-
$(CONTAINER_TOOL) push $(ACTIVATOR_IMG)
190-
191173
##@ Install/Uninstall Targets
192174

193175
# Default install/uninstall (Docker)

charts/activator/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ The following table list the configurable parameters of the chart.
3636
| `activator.image.pullPolicy` | Image pull policy for the container. Possible values: `Always`, `IfNotPresent`, or `Never`. Defaults to `Always`. |
3737
| `inferenceGateway.port` | The port of the Gateway. Defaults to `80`. |
3838
| `inferencePool.name` | The name of the InferencePool to target. |
39-
| `inferencePool.apiVersion` | The API version of the InferencePool. Defaults to `inference.networking.x-k8s.io`. |
39+
| `inferencePool.apiVersion` | The API version of the InferencePool. Defaults to `inference.networking.k8s.io`. |
4040
| `route.name` | The name of the HTTPRoute to attach the activator to. |
4141

4242
## Notes

charts/activator/values.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ route:
1313

1414
inferencePool:
1515
name: inference-pool
16-
group: inference.networking.x-k8s.io
16+
group: inference.networking.k8s.io
1717

1818
inferenceGateway:
1919
port: 80

0 commit comments

Comments
 (0)