forked from elastic/kibana
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Spacetime][Fleet] Introduce airgapped config for bundled packages (e…
…lastic#202435) Closes elastic#136617 Closes elastic#167195 ## Summary [Spacetime] Improving Integrations experience on airgapped envs using the existing `xpack.fleet.isAirGapped` configuration key: - Loading integrations is now much faster and doesn't attempt to contact the registry at all - Installing an uninstalled bundled packages should now be possible NOTE: Setting the `isAirGapped` skips the calls to registry altogether ### Testing - In `kibana.dev.yml`: - Make sure that APM and other bundled packages are not present in preconfiguration - Configure `xpack.fleet.registryUrl` to an unreacheable host, i.e. `xpack.fleet.registryUrl: http://notworking` - Configure `xpack.fleet.isAirGapped: true` - Copy the zip files from the EPR for some common bundled packages to them in `them in kibana/x-pack/plugins/fleet/target/bundled_packages` - Navigate to Integrations and verify that the page loads faster than in the past (it would take long because of retries) - Navigate to apm page or to`app/integrations/detail/apm-8.4.2/overview` - Try to install it it should succeed correctly ### Checklist - [ ] [Documentation](https://www.elastic.co/guide/en/kibana/master/development-documentation.html) was added for features that require explanation or tutorials - [ ] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios --------- Co-authored-by: Elastic Machine <[email protected]>
- Loading branch information
1 parent
6220c57
commit c3f96bb
Showing
13 changed files
with
391 additions
and
152 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -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 { appContextService } from '..'; | ||
|
||
export const airGappedUtils = () => { | ||
const config = appContextService.getConfig(); | ||
const hasRegistryUrls = config?.registryUrl || config?.registryProxyUrl; | ||
const isAirGapped = config?.isAirGapped; | ||
|
||
const shouldSkipRegistryRequests = isAirGapped && !hasRegistryUrls; | ||
|
||
return { hasRegistryUrls, isAirGapped, shouldSkipRegistryRequests }; | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.