From 426f4ad081de6869e3a81860c347660e7b28e5ab Mon Sep 17 00:00:00 2001 From: Chaoyi Sun Date: Wed, 3 Jul 2024 21:06:34 -0700 Subject: [PATCH] #179 update ci profile to use fabric8 for multi-platform docker build --- build-parent/pom.xml | 18 ----- .../dao/VaultPropertyDaoSteps.java | 11 +--- extensions/extensions-docker/pom.xml | 66 +++++++++++-------- .../tests/features/environment.py | 20 +----- .../data/encryption/HashingSteps.java | 11 +--- .../tests/features/environment.py | 9 +-- .../docker-compose-arm64.yml | 17 ----- .../docker-compose.yml | 2 +- 8 files changed, 45 insertions(+), 109 deletions(-) delete mode 100644 test/test-mda-models/aissemble-test-data-delivery-pyspark-model/tests/resources/integration-test-resources/docker-compose-arm64.yml diff --git a/build-parent/pom.xml b/build-parent/pom.xml index 519edbe99..9fcf4751a 100644 --- a/build-parent/pom.xml +++ b/build-parent/pom.xml @@ -1090,24 +1090,6 @@ To suppress enforce-helm-version rule, you must add following plugin to the root true - - arm64 - - - - - org.technologybrewery.habushu - habushu-maven-plugin - ${version.habushu.plugin} - - - true - - - - - - diff --git a/extensions/extensions-configuration-store-vault/src/test/java/com/boozallen/aissemble/configuration/dao/VaultPropertyDaoSteps.java b/extensions/extensions-configuration-store-vault/src/test/java/com/boozallen/aissemble/configuration/dao/VaultPropertyDaoSteps.java index 2c759398e..9b325a8c7 100644 --- a/extensions/extensions-configuration-store-vault/src/test/java/com/boozallen/aissemble/configuration/dao/VaultPropertyDaoSteps.java +++ b/extensions/extensions-configuration-store-vault/src/test/java/com/boozallen/aissemble/configuration/dao/VaultPropertyDaoSteps.java @@ -88,7 +88,7 @@ public void theConfigLoaderUsesVaultPropertyDaoToWriteToVault() { private void setupVaultContainer() { final Properties encryptProperties = Krausening.getInstance().getProperties("encrypt.properties"); - String dockerImage = "ghcr.io/boozallen/aissemble-vault:" + System.getProperty("version.aissemble.vault") + this.getSystemArchitectureTag(); + String dockerImage = "ghcr.io/boozallen/aissemble-vault:" + System.getProperty("version.aissemble.vault"); final DockerImageName vaultImage = DockerImageName.parse(dockerImage).asCompatibleSubstituteFor("vault"); vaultContainer = new VaultContainer(vaultImage); vaultContainer.setWaitStrategy(Wait.forListeningPort()); @@ -106,15 +106,6 @@ private void setupVaultContainer() { encryptProperties.setProperty("secrets.unseal.keys", unsealKeysJSONArrayString.replaceAll("[\\s|\\[\\]\"]", "")); } - private String getSystemArchitectureTag() { - String arch = System.getProperty("os.arch").toLowerCase().trim(); - switch(arch) { - case "aarch64": - case "arm64": return "-arm64"; - default: return "-amd64"; - } - } - private String inputStreamToString(InputStream inputStream) { try { return new String(inputStream.readAllBytes()); diff --git a/extensions/extensions-docker/pom.xml b/extensions/extensions-docker/pom.xml index 7e1c4567e..b024364b9 100644 --- a/extensions/extensions-docker/pom.xml +++ b/extensions/extensions-docker/pom.xml @@ -18,37 +18,47 @@ - x86 - - amd64 - linux/amd64 - - - - arm64 - - arm64 - linux/arm64 - + ci - - - - maven-deploy-plugin - - true - - - - + + + io.fabric8 + docker-maven-plugin + + + default-push + + + + ${docker.baseline.repo.id}/${dockerImageName}:${dockerImageVersion} + + + + ${docker.platforms} + + + + ${version.delta.hive.connector} + ${docker.baseline.repo.id}/ + ${version.aissemble} + ${version.spark} + + ${project.basedir} + ./src/main/resources/docker/Dockerfile + + + + + + push + + deploy + + + + - - ci - - ${project.version}-${target.architecture} - - ensure-docker-dependencies