diff --git a/x-pack/plugins/fleet/server/saved_objects/index.ts b/x-pack/plugins/fleet/server/saved_objects/index.ts index bc52fa2e2017a..3c85d35595f7f 100644 --- a/x-pack/plugins/fleet/server/saved_objects/index.ts +++ b/x-pack/plugins/fleet/server/saved_objects/index.ts @@ -40,6 +40,7 @@ import { migrateInstallationToV7160, migratePackagePolicyToV7160 } from './migra import { migrateInstallationToV800, migrateOutputToV800 } from './migrations/to_v8_0_0'; import { migratePackagePolicyToV820 } from './migrations/to_v8_2_0'; import { migrateInstallationToV830, migratePackagePolicyToV830 } from './migrations/to_v8_3_0'; +import { migrateInstallationToV840 } from './migrations/to_v8_4_0'; /* * Saved object types and mappings @@ -268,6 +269,7 @@ const getSavedObjectTypes = ( '7.16.0': migrateInstallationToV7160, '8.0.0': migrateInstallationToV800, '8.3.0': migrateInstallationToV830, + '8.4.0': migrateInstallationToV840, }, }, [ASSETS_SAVED_OBJECT_TYPE]: { diff --git a/x-pack/plugins/fleet/server/saved_objects/migrations/to_v8_4_0.ts b/x-pack/plugins/fleet/server/saved_objects/migrations/to_v8_4_0.ts new file mode 100644 index 0000000000000..203e26c0a2e19 --- /dev/null +++ b/x-pack/plugins/fleet/server/saved_objects/migrations/to_v8_4_0.ts @@ -0,0 +1,18 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import type { SavedObjectMigrationFn } from '@kbn/core/server'; + +import type { Installation } from '../../../common'; + +export const migrateInstallationToV840: SavedObjectMigrationFn = ( + installationDoc +) => { + installationDoc.attributes.verification_status = 'unknown'; + + return installationDoc; +};