@@ -40,7 +40,7 @@ KUBERNETES_DOC_VERSION=v1.30
40
40
# ----------------------------------------------------------------------------------------------------------------------
41
41
# The Coherence version to build against - must be a Java 8 compatible version
42
42
COHERENCE_VERSION ?= 21.12.5
43
- COHERENCE_VERSION_LTS ?= 14.1.2-0-0
43
+ COHERENCE_VERSION_LTS ?= 14.1.2-0-1
44
44
# The default Coherence image the Operator will run if no image is specified
45
45
COHERENCE_IMAGE_REGISTRY ?= ghcr.io/oracle
46
46
COHERENCE_IMAGE_NAME ?= coherence-ce
@@ -358,7 +358,24 @@ METALLB_VERSION ?= v0.12.1
358
358
# Istio settings
359
359
# ----------------------------------------------------------------------------------------------------------------------
360
360
# The version of Istio to install, leave empty for the latest
361
- ISTIO_VERSION ?=
361
+ ISTIO_VERSION ?=
362
+ ISTIO_PROFILE ?= demo
363
+ ISTIO_USE_CONFIG ?= false
364
+ ifeq (,$(ISTIO_VERSION ) )
365
+ ISTIO_VERSION_USE := $(shell $(SCRIPTS_DIR)/find-istio-version.sh "$(TOOLS_DIRECTORY)/istio-latest.txt")
366
+ ISTIO_REVISION := $(subst .,-,$(ISTIO_VERSION_USE))
367
+ ISTIO_HOME := $(TOOLS_DIRECTORY)/istio-$(ISTIO_VERSION_USE)
368
+ else
369
+ ifeq (latest,$(ISTIO_VERSION ) )
370
+ ISTIO_VERSION_USE := $(shell $(SCRIPTS_DIR)/find-istio-version.sh "$(TOOLS_DIRECTORY)/istio-latest.txt")
371
+ ISTIO_REVISION := $(subst .,-,$(ISTIO_VERSION_USE))
372
+ ISTIO_HOME := $(TOOLS_DIRECTORY)/istio-$(ISTIO_VERSION_USE)
373
+ else
374
+ ISTIO_VERSION_USE := $(ISTIO_VERSION)
375
+ ISTIO_REVISION := $(subst .,-,$(ISTIO_VERSION))
376
+ ISTIO_HOME := $(TOOLS_DIRECTORY)/istio-$(ISTIO_VERSION)
377
+ endif
378
+ endif
362
379
363
380
# ----------------------------------------------------------------------------------------------------------------------
364
381
# Tanzu settings
@@ -415,6 +432,9 @@ $(BUILD_PROPS):
415
432
OPERATOR_IMAGE_NAME=$(OPERATOR_IMAGE_NAME ) \n \
416
433
OPERATOR_IMAGE=$(OPERATOR_IMAGE ) \n \
417
434
VERSION=$(VERSION ) \n \
435
+ ISTIO_VERSION_USE=$(ISTIO_VERSION_USE ) \n \
436
+ ISTIO_REVISION=$(ISTIO_REVISION ) \n \
437
+ ISTIO_PROFILE=$(ISTIO_PROFILE ) \n \
418
438
OPERATOR_PACKAGE_IMAGE=$(OPERATOR_PACKAGE_IMAGE ) \n " > $( BUILD_PROPS)
419
439
420
440
# ----------------------------------------------------------------------------------------------------------------------
@@ -1739,6 +1759,7 @@ k3d-create: $(TOOLS_BIN)/k3d ## Create the k3d cluster
1739
1759
--registry-use $(K3D_INTERNAL_REGISTRY ) --no-lb \
1740
1760
--runtime-ulimit " nofile=64000:64000" --runtime-ulimit " nproc=64000:64000" \
1741
1761
--api-port 127.0.0.1:6550
1762
+ $(SCRIPTS_DIR ) /k3d-label-node.sh
1742
1763
1743
1764
.PHONY : k3d-stop
1744
1765
k3d-stop : $(TOOLS_BIN ) /k3d # # Stop a default k3d cluster
@@ -2273,39 +2294,53 @@ uninstall-metallb: ## Uninstall MetalLB
2273
2294
# Install the latest Istio version
2274
2295
# ----------------------------------------------------------------------------------------------------------------------
2275
2296
.PHONY : install-istio
2276
- install-istio : get-istio # # Install the latest version of Istio into k8s (or override the version using the ISTIO_VERSION env var)
2277
- $(eval ISTIO_HOME := $(shell find $(TOOLS_DIRECTORY ) -maxdepth 1 -type d | grep istio) )
2278
- $(ISTIO_HOME ) /bin/istioctl install --set profile=demo -y
2279
- kubectl -n istio-system wait --for condition=available deployment.apps/istiod
2297
+ install-istio : delete-istio-config get-istio # # Install the latest version of Istio into k8s (or override the version using the ISTIO_VERSION env var)
2298
+ $(ISTIO_HOME ) /bin/istioctl install -f $(BUILD_OUTPUT ) /istio-config.yaml -y
2299
+ kubectl -n istio-system wait --for condition=available deployment.apps/istiod-$(ISTIO_REVISION )
2280
2300
kubectl -n istio-system wait --for condition=available deployment.apps/istio-ingressgateway
2281
2301
kubectl -n istio-system wait --for condition=available deployment.apps/istio-egressgateway
2282
- kubectl apply -f ./hack /istio-strict.yaml
2283
- kubectl -n $(OPERATOR_NAMESPACE ) apply -f ./hack /istio-operator.yaml
2302
+ kubectl apply -f $( SCRIPTS_DIR ) /istio-strict.yaml
2303
+ kubectl -n $(OPERATOR_NAMESPACE ) apply -f $( SCRIPTS_DIR ) /istio-operator.yaml
2284
2304
kubectl label namespace $(OPERATOR_NAMESPACE ) istio-injection=enabled --overwrite=true
2285
2305
kubectl label namespace $(OPERATOR_NAMESPACE_CLIENT ) istio-injection=enabled --overwrite=true
2286
2306
kubectl label namespace $(CLUSTER_NAMESPACE ) istio-injection=enabled --overwrite=true
2287
2307
kubectl apply -f $(ISTIO_HOME ) /samples/addons
2288
2308
2309
+ # ----------------------------------------------------------------------------------------------------------------------
2310
+ # Upgrade Istio
2311
+ # ----------------------------------------------------------------------------------------------------------------------
2312
+ .PHONY : upgrade-istio
2313
+ upgrade-istio : delete-istio-config $(BUILD_OUTPUT ) /istio-config.yaml # # Upgrade an already installed Istio to the Istio version specified by ISTIO_VERSION
2314
+ $(ISTIO_HOME ) /bin/istioctl upgrade -f $(SCRIPTS_DIR ) /istio-config.yaml -y
2315
+
2289
2316
# ----------------------------------------------------------------------------------------------------------------------
2290
2317
# Uninstall Istio
2291
2318
# ----------------------------------------------------------------------------------------------------------------------
2292
2319
.PHONY : uninstall-istio
2293
- uninstall-istio : get-istio # # Uninstall Istio from k8s
2294
- kubectl -n $(OPERATOR_NAMESPACE ) delete -f ./hack/istio-operator.yaml || true
2295
- kubectl delete -f ./hack/istio-strict.yaml
2296
- $(eval ISTIO_HOME := $(shell find $(TOOLS_DIRECTORY ) -maxdepth 1 -type d | grep istio) )
2320
+ uninstall-istio : delete-istio-config get-istio # # Uninstall Istio from k8s
2321
+ kubectl -n $(OPERATOR_NAMESPACE ) delete -f $(SCRIPTS_DIR ) /istio-operator.yaml || true
2322
+ kubectl delete -f ./hack/istio-strict.yaml || true
2297
2323
$(ISTIO_HOME ) /bin/istioctl uninstall --purge -y
2298
2324
2325
+ $(BUILD_OUTPUT ) /istio-config.yaml : $(BUILD_PROPS )
2326
+ @echo " Creating Istio config: rev=$( ISTIO_REVISION) "
2327
+ cp $(SCRIPTS_DIR ) /istio-config.yaml $(BUILD_OUTPUT ) /istio-config.yaml
2328
+ $(SED ) -e ' s/ISTIO_PROFILE/$(ISTIO_PROFILE)/g' $(BUILD_OUTPUT ) /istio-config.yaml
2329
+ $(SED ) -e ' s/ISTIO_REVISION/$(ISTIO_REVISION)/g' $(BUILD_OUTPUT ) /istio-config.yaml
2330
+
2331
+ .PHONY : delete-istio-config
2332
+ delete-istio-config :
2333
+ rm $(BUILD_OUTPUT ) /istio-config.yaml || true
2299
2334
2300
2335
# ----------------------------------------------------------------------------------------------------------------------
2301
2336
# Get the latest Istio version
2302
2337
# ----------------------------------------------------------------------------------------------------------------------
2303
2338
.PHONY : get-istio
2304
- get-istio : $(BUILD_PROPS )
2305
- $(SCRIPTS_DIR ) /get-istio-latest.sh " $( ISTIO_VERSION) " " $( TOOLS_DIRECTORY) "
2306
- $(eval ISTIO_HOME := $(shell find $(TOOLS_DIRECTORY ) -maxdepth 1 -type d | grep istio) )
2339
+ get-istio : $(BUILD_PROPS ) $(BUILD_OUTPUT ) /istio-config.yaml # # Download Istio to the build/tools/istio-* directory
2340
+ $(SCRIPTS_DIR ) /get-istio-latest.sh " $( ISTIO_VERSION_USE) " " $( TOOLS_DIRECTORY) "
2307
2341
@echo " Istio installed at $( ISTIO_HOME) "
2308
2342
2343
+
2309
2344
# ----------------------------------------------------------------------------------------------------------------------
2310
2345
# Obtain the golangci-lint binary
2311
2346
# ----------------------------------------------------------------------------------------------------------------------
0 commit comments