import { CloudProvider } from '../k8s-cluster/base' ; import { AksFullNodeDeployer , AksFullNodeDeploymentConfig } from './aks' ; import { AwsFullNodeDeployer , AwsFullNodeDeploymentConfig } from './aws' ; import { BaseFullNodeDeployer , BaseFullNodeDeploymentConfig } from './base' ; import { GCPFullNodeDeployer , GCPFullNodeDeploymentConfig } from './gcp' ; const fullNodeDeployerByCloudProvider = { [ CloudProvider . AWS ] : ( deploymentConfig , celoEnv ) => new AwsFullNodeDeployer ( deploymentConfig as AwsFullNodeDeploymentConfig , celoEnv ) , [ CloudProvider . AZURE ] : ( deploymentConfig , celoEnv ) => new AksFullNodeDeployer ( deploymentConfig as AksFullNodeDeploymentConfig , celoEnv ) , [ CloudProvider . GCP ] : ( deploymentConfig , celoEnv ) => new GCPFullNodeDeployer ( deploymentConfig as GCPFullNodeDeploymentConfig , celoEnv ) , } ; export function getFullNodeDeployer ( cloudProvider , celoEnv , deploymentConfig ) { return fullNodeDeployerByCloudProvider [ cloudProvider ] ( deploymentConfig , celoEnv ) ; }