diff --git a/x-pack/plugins/fleet/common/experimental_features.ts b/x-pack/plugins/fleet/common/experimental_features.ts index 638e48cae5ba4..67abb5dfca379 100644 --- a/x-pack/plugins/fleet/common/experimental_features.ts +++ b/x-pack/plugins/fleet/common/experimental_features.ts @@ -19,7 +19,7 @@ export const allowedExperimentalValues = Object.freeze({ experimentalDataStreamSettings: false, displayAgentMetrics: true, showIntegrationsSubcategories: true, - agentFqdnMode: false, + agentFqdnMode: true, showExperimentalShipperOptions: false, fleetServerStandalone: false, agentTamperProtectionEnabled: false, diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_advanced_fields/index.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_advanced_fields/index.tsx index 6409114839bc6..407352a69bebf 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_advanced_fields/index.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_advanced_fields/index.tsx @@ -42,7 +42,7 @@ import { AgentPolicyPackageBadge } from '../../../../components'; import { AgentPolicyDeleteProvider } from '../agent_policy_delete_provider'; import type { ValidationResults } from '../agent_policy_validation'; -import { ExperimentalFeaturesService, policyHasFleetServer } from '../../../../services'; +import { policyHasFleetServer } from '../../../../services'; import { useOutputOptions, @@ -66,7 +66,6 @@ export const AgentPolicyAdvancedOptionsContent: React.FunctionComponent = isEditing = false, onDelete = () => {}, }) => { - const { agentFqdnMode: agentFqdnModeEnabled } = ExperimentalFeaturesService.get(); const { docLinks } = useStartServices(); const config = useConfig(); const maxAgentPoliciesWithInactivityTimeout = @@ -558,66 +557,38 @@ export const AgentPolicyAdvancedOptionsContent: React.FunctionComponent = /> - {agentFqdnModeEnabled && ( - - -   - - - } - description={ + - } - > - - - - - - - - - - - - - - - - - - - ), - }, - { - id: 'fqdn', - label: ( +   + + + } + description={ + + } + > + + @@ -625,26 +596,52 @@ export const AgentPolicyAdvancedOptionsContent: React.FunctionComponent = - ), - }, - ]} - idSelected={agentPolicy.agent_features?.length ? 'fqdn' : 'hostname'} - onChange={(id: string) => { - updateAgentPolicy({ - agent_features: id === 'hostname' ? [] : [{ name: 'fqdn', enabled: true }], - }); - }} - name="radio group" - /> - - - )} + + + ), + }, + { + id: 'fqdn', + label: ( + + + + + + + + + + + + + + + ), + }, + ]} + idSelected={agentPolicy.agent_features?.length ? 'fqdn' : 'hostname'} + onChange={(id: string) => { + updateAgentPolicy({ + agent_features: id === 'hostname' ? [] : [{ name: 'fqdn', enabled: true }], + }); + }} + name="radio group" + /> + + {isEditing && 'id' in agentPolicy && !agentPolicy.is_managed ? (