public static InfraDeployerProvider withInfraDeployer(InfraDeployer infraDeployer) {
        ComponentRegistry<InfraDeployer> registry = new ComponentRegistry<>();
        registry.register(ComponentId.createAnonymousComponentId("foobar"), infraDeployer);
        return new InfraDeployerProvider(registry, new ConfigserverConfig(new ConfigserverConfig.Builder().hostedVespa(true)));
    }
Returns the infrastructure deployer, or empty if we are not in hosted mode
configserver/src/main/java/com/yahoo/vespa/config/server/deploy/InfraDeployerProvider.java