Load images (#1649)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
This commit is contained in:
erabii
2024-04-30 14:18:02 +03:00
committed by GitHub
parent 4336a5b59c
commit 95e49167a6
5 changed files with 28 additions and 8 deletions

View File

@@ -63,8 +63,8 @@ public class LeaderInitiator implements SmartLifecycle {
hostPodWatcher.start();
scheduledExecutorService = Executors.newSingleThreadScheduledExecutor();
scheduledExecutorService.scheduleAtFixedRate(leadershipController::update,
leaderProperties.getUpdatePeriod().toMillis(),
leaderProperties.getUpdatePeriod().toMillis(), TimeUnit.MILLISECONDS);
leaderProperties.getUpdatePeriod().toMillis(), leaderProperties.getUpdatePeriod().toMillis(),
TimeUnit.MILLISECONDS);
isRunning = true;
}
}

View File

@@ -65,7 +65,9 @@ class Fabric8IstioIT {
Commons.validateImage(IMAGE_NAME, K3S);
Commons.loadSpringCloudKubernetesImage(IMAGE_NAME, K3S);
Images.loadIstioctl(K3S);
Images.loadIstioCtl(K3S);
Images.loadIstioProxyV2(K3S);
Images.loadIstioPilot(K3S);
processExecResult(K3S.execInContainer("sh", "-c", "kubectl create namespace istio-test"));
processExecResult(

View File

@@ -36,7 +36,15 @@ public final class Images {
private static final String ISTIOCTL = "istio/istioctl";
private static final String ISTIOCTL_TAR = ISTIOCTL.replace('/', '-') + ":" + istioctlVersion();
private static final String ISTIOCTL_TAR = ISTIOCTL.replace('/', '-') + ":" + istioVersion();
private static final String ISTIO_PROXY_V2 = "istio/proxyv2";
private static final String ISTIO_PROXY_V2_TAR = ISTIO_PROXY_V2.replace('/', '-') + ":" + istioVersion();
private static final String ISTIO_PILOT = "istio/istioctl";
private static final String ISTIO_PILOT_TAR = ISTIO_PILOT.replace('/', '-') + ":" + istioVersion();
private static final String KAFKA = "confluentinc/cp-kafka";
@@ -54,7 +62,7 @@ public final class Images {
return imageVersion(BUSYBOX);
}
public static String istioctlVersion() {
public static String istioVersion() {
return imageVersion(ISTIOCTL);
}
@@ -78,8 +86,16 @@ public final class Images {
Commons.load(container, WIREMOCK_TAR, WIREMOCK, wiremockVersion());
}
public static void loadIstioctl(K3sContainer container) {
Commons.load(container, ISTIOCTL_TAR, ISTIOCTL, istioctlVersion());
public static void loadIstioCtl(K3sContainer container) {
Commons.load(container, ISTIOCTL_TAR, ISTIOCTL, istioVersion());
}
public static void loadIstioProxyV2(K3sContainer container) {
Commons.load(container, ISTIO_PROXY_V2_TAR, ISTIO_PROXY_V2, istioVersion());
}
public static void loadIstioPilot(K3sContainer container) {
Commons.load(container, ISTIO_PILOT_TAR, ISTIO_PILOT, istioVersion());
}
public static void loadKafka(K3sContainer container) {

View File

@@ -267,7 +267,7 @@ public final class Util {
String imageWithoutVersion = istioctlDeployment.getSpec().getTemplate().getSpec().getContainers().get(0)
.getImage();
String imageWithVersion = imageWithoutVersion + ":" + Images.istioctlVersion();
String imageWithVersion = imageWithoutVersion + ":" + Images.istioVersion();
istioctlDeployment.getSpec().getTemplate().getSpec().getContainers().get(0).setImage(imageWithVersion);
if (phase.equals(Phase.CREATE)) {

View File

@@ -1,5 +1,7 @@
busybox:1.36.1
istio/istioctl:1.20.5
istio/proxyv2:1.20.5
istio/pilot:1.20.5
confluentinc/cp-kafka:7.2.1
rabbitmq:3-management
wiremock/wiremock:3.4.2