@@ -842,7 +842,7 @@ def _configure_payload(self):
842842 payload ['authentication' ] = dict (publicKey = self .public_key_text )
843843
844844 if self .freeipa is not None :
845- payload ['freeIpa' ] = dict (instanceCountByGroup = self .freeipa )
845+ payload ['freeIpa' ] = dict (instanceCountByGroup = self .freeipa [ 'instanceCountByGroup' ] )
846846
847847 if self .vpc_id is not None :
848848 payload ['vpcId' ] = self .vpc_id
@@ -875,6 +875,8 @@ def _configure_payload(self):
875875 )
876876 payload ['usePublicIp' ] = self .public_ip
877877 payload ['logStorage' ] = dict (serviceAccountEmail = self .log_identity , storageLocationBase = self .log_location )
878+ if self .freeipa is not None :
879+ payload ['freeIpa' ] = dict (instanceCountByGroup = self .freeipa ['instanceCountByGroup' ])
878880 else :
879881 # For Azure
880882 payload ['securityAccess' ] = dict (defaultSecurityGroupId = self .default_sg ,
@@ -886,6 +888,8 @@ def _configure_payload(self):
886888 payload ['existingNetworkParams' ] = dict (
887889 networkId = self .vpc_id , resourceGroupName = self .resource_gp , subnetIds = self .subnet_ids
888890 )
891+ if self .freeipa is not None :
892+ payload ['freeIpa' ] = dict (instanceCountByGroup = self .freeipa ['instanceCountByGroup' ])
889893
890894 return payload
891895
@@ -928,7 +932,7 @@ def _reconcile_existing_state(self, existing):
928932 if self .description is not None and existing ['description' ] != self .description :
929933 mismatch .append (['description' , existing ['description' ]])
930934
931- if self .freeipa is not None and len (existing ['freeipa' ]['serverIP' ]) != self .freeipa :
935+ if self .freeipa is not None and len (existing ['freeipa' ]['serverIP' ]) != self .freeipa [ 'instanceCountByGroup' ] :
932936 mismatch .append (['freeipa' , len (existing ['freeipa' ]['serverIP' ])])
933937
934938 if self .vpc_id is not None and existing ['network' ]['aws' ]['vpcId' ] != self .vpc_id :
0 commit comments