resource "citrix_stf_authentication_service" "config-authentication-service" { friendly_name = "StoreAuth" virtual_path = "/Citrix/StoreAuth" site_id = citrix_stf_deployment.config-main-site.site_id depends_on = [ citrix_stf_deployment.config-main-site ] //Required dependency } ### Create Each Store resource "citrix_stf_store_service" "config-store" { friendly_name = "Store" virtual_path = "/Citrix/Store" authentication_service_virtual_path = citrix_stf_authentication_service.config-authentication-service.virtual_path #Controllers/Farms farms = [ { farm_name = "Farm" farm_type = "XenDesktop" servers = ["Farm1Server1","Farm1Server2"] }, { farm_name = "Farm2" farm_type = "XenDesktop" servers = ["Farm1Server2","Farm2Server2"] } ] // Add depends_on attribute to ensure the StoreFront Store with Authentication is created after the Authentication Service site_id = citrix_stf_deployment.config-main-site.site_id depends_on = [ citrix_stf_authentication_service.config-authentication-service ] } resource "citrix_stf_user_farm_mapping" "example-stf-user-farm-mapping" { name = "Example STFUserFarmMapping" store_virtual_path = "/Citrix/Store" group_members = [ { group_name = "Group1" account_sid = "S-1-5-21-1703298208-4135396963-2854486448-1104" } ] equivalent_farm_sets = [ { name = "EU1", aggregation_group_name = "EU1Users" primary_farms = [ "Farm1" ] backup_farms = [ "Farm2" ] load_balance_mode = "LoadBalanced" farms_are_identical = true } ] // Add depends_on attribute to ensure the User Farm Mapping is created after the Store Service and Store Farms depends_on = [ citrix_stf_store_service.config-store ] }