From e90d7b4ba33b6d687d2d9c9a03dc2939624d1f9e Mon Sep 17 00:00:00 2001 From: Jonathan Budzenski Date: Fri, 27 Dec 2024 13:32:26 -0600 Subject: [PATCH] [ci] Use daily promoted EPR distribution --- .../kibana-package-registry.yml | 1 + .../integration_tests/helpers/docker_registry_helper.ts | 6 +++++- x-pack/test/fleet_api_integration/config.base.ts | 9 +++++---- x-pack/test/functional/config.base.js | 9 +++++---- 4 files changed, 16 insertions(+), 9 deletions(-) diff --git a/.buildkite/pipeline-resource-definitions/kibana-package-registry.yml b/.buildkite/pipeline-resource-definitions/kibana-package-registry.yml index 392a511e22281..9b4fe89cbc49d 100644 --- a/.buildkite/pipeline-resource-definitions/kibana-package-registry.yml +++ b/.buildkite/pipeline-resource-definitions/kibana-package-registry.yml @@ -21,6 +21,7 @@ spec: env: SLACK_NOTIFICATIONS_CHANNEL: "#kibana-operations-alerts" ELASTIC_SLACK_NOTIFICATIONS_ENABLED: "false" + FLEET_PACKAGE_REGISTRY_DOCKER_IMAGE: docker.elastic.co/package-registry/distribution:lite repository: elastic/kibana branch_configuration: main default_branch: main diff --git a/x-pack/platform/plugins/shared/fleet/server/integration_tests/helpers/docker_registry_helper.ts b/x-pack/platform/plugins/shared/fleet/server/integration_tests/helpers/docker_registry_helper.ts index d65a323e84d5b..8c5792b37807d 100644 --- a/x-pack/platform/plugins/shared/fleet/server/integration_tests/helpers/docker_registry_helper.ts +++ b/x-pack/platform/plugins/shared/fleet/server/integration_tests/helpers/docker_registry_helper.ts @@ -18,7 +18,11 @@ import pRetry from 'p-retry'; const BEFORE_SETUP_TIMEOUT = 30 * 60 * 1000; // 30 minutes; const DOCKER_START_TIMEOUT = 5 * 60 * 1000; // 5 minutes -const DOCKER_IMAGE = `docker.elastic.co/package-registry/distribution:lite`; +// This image comes from the latest successful build of https://buildkite.com/elastic/kibana-package-registry-promote +// which is promoted after acceptance tests succeed against docker.elastic.co/package-registry/distribution:lite +const DOCKER_IMAGE = + process.env.FLEET_PACKAGE_REGISTRY_DOCKER_IMAGE || + 'docker.elastic.co/kibana-ci/package-registry-distribution:lite'; function firstWithTimeout(source$: Rx.Observable, errorMsg: string, ms = 30 * 1000) { return Rx.race( diff --git a/x-pack/test/fleet_api_integration/config.base.ts b/x-pack/test/fleet_api_integration/config.base.ts index 1be78bcdc04df..852b0be4f82ac 100644 --- a/x-pack/test/fleet_api_integration/config.base.ts +++ b/x-pack/test/fleet_api_integration/config.base.ts @@ -15,10 +15,11 @@ import { const getFullPath = (relativePath: string) => path.join(path.dirname(__filename), relativePath); // Docker image to use for Fleet API integration tests. -// This hash comes from the latest successful build of the Production Distribution of the Package Registry, for -// example: https://internal-ci.elastic.co/blue/organizations/jenkins/package_storage%2Findexing-job/detail/main/1884/pipeline/147. -// It should be updated any time there is a new package published. -export const dockerImage = 'docker.elastic.co/package-registry/distribution:lite'; +// This image comes from the latest successful build of https://buildkite.com/elastic/kibana-package-registry-promote +// which is promoted after acceptance tests succeed against docker.elastic.co/package-registry/distribution:lite +export const dockerImage = + process.env.FLEET_PACKAGE_REGISTRY_DOCKER_IMAGE || + 'docker.elastic.co/kibana-ci/package-registry-distribution:lite'; export const BUNDLED_PACKAGE_DIR = '/tmp/fleet_bundled_packages'; diff --git a/x-pack/test/functional/config.base.js b/x-pack/test/functional/config.base.js index b3d2ddc1e2f78..24a4a63d53dda 100644 --- a/x-pack/test/functional/config.base.js +++ b/x-pack/test/functional/config.base.js @@ -11,10 +11,11 @@ import { services } from './services'; import { pageObjects } from './page_objects'; // Docker image to use for Fleet API integration tests. -// This hash comes from the latest successful build of the Production Distribution of the Package Registry, for -// example: https://internal-ci.elastic.co/blue/organizations/jenkins/package_storage%2Findexing-job/detail/main/1884/pipeline/147. -// It should be updated any time there is a new package published. -export const dockerImage = 'docker.elastic.co/package-registry/distribution:lite'; +// This image comes from the latest successful build of https://buildkite.com/elastic/kibana-package-registry-promote +// which is promoted after acceptance tests succeed against docker.elastic.co/package-registry/distribution:lite +export const dockerImage = + process.env.FLEET_PACKAGE_REGISTRY_DOCKER_IMAGE || + 'docker.elastic.co/kibana-ci/package-registry-distribution:lite'; // the default export of config files must be a config provider // that returns an object with the projects config values