You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

230 lines
11 KiB

  1. version: '3.4'
  2. # The Production docker-compose file has to have the external/real IPs or DNS names for the services
  3. # The ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP environment variable is taken, by default, from the ".env" file defined like:
  4. # ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP=192.168.88.248
  5. # but values present in the environment vars at runtime will always override those defined inside the .env file
  6. # An external IP or DNS name has to be used when testing the Web apps and the Xamarin apps from remote machines/devices using the same WiFi, for instance.
  7. #
  8. # IMPORTANT: Note that this compose file uses ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP instead of ESHOP_EXTERNAL_DNS_NAME_OR_IP
  9. # Set ASPNETCORE_ENVIRONMENT= Development or Production, depending if you want to show up errors while testing.
  10. #
  11. # You need to start it with the following CLI command:
  12. # docker-compose -f docker-compose.yml -f docker-compose.prod.yml up -d
  13. services:
  14. basket.api:
  15. environment:
  16. - ASPNETCORE_ENVIRONMENT=Development
  17. - ASPNETCORE_URLS=http://0.0.0.0:80
  18. - ConnectionString=${ESHOP_AZURE_REDIS_BASKET_DB:-basket.data}
  19. - identityUrl=http://identity.api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  20. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  21. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  22. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  23. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  24. - AzureServiceBusEnabled=False
  25. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  26. - OrchestratorType=${ORCHESTRATOR_TYPE}
  27. - UseLoadTest=${USE_LOADTEST:-False}
  28. ports:
  29. - "5103:80"
  30. catalog.api:
  31. environment:
  32. - ASPNETCORE_ENVIRONMENT=Development
  33. - ASPNETCORE_URLS=http://0.0.0.0:80
  34. - ConnectionString=${ESHOP_AZURE_CATALOG_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Services.CatalogDb;User Id=sa;Password=Pass@word}
  35. - PicBaseUrl=${ESHOP_AZURE_STORAGE_CATALOG_URL:-http://localhost:5101/api/v1/catalog/items/[0]/pic/} #Local: You need to open your local dev-machine firewall at range 5100-5110.
  36. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  37. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  38. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  39. - AzureStorageAccountName=${ESHOP_AZURE_STORAGE_CATALOG_NAME}
  40. - AzureStorageAccountKey=${ESHOP_AZURE_STORAGE_CATALOG_KEY}
  41. - UseCustomizationData=True
  42. - AzureServiceBusEnabled=False
  43. - AzureStorageEnabled=False
  44. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  45. - OrchestratorType=${ORCHESTRATOR_TYPE}
  46. ports:
  47. - "5101:80"
  48. identity.api:
  49. environment:
  50. - ASPNETCORE_ENVIRONMENT=Development
  51. - ASPNETCORE_URLS=http://0.0.0.0:80
  52. - SpaClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5104
  53. - XamarinCallback=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105/xamarincallback #localhost do not work for UWP login, so we have to use "external" IP always
  54. - ConnectionString=${ESHOP_AZURE_IDENTITY_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Service.IdentityDb;User Id=sa;Password=Pass@word}
  55. - MvcClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5100 #Local: You need to open your local dev-machine firewall at range 5100-5110.
  56. - LocationApiClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5109
  57. - MarketingApiClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5110
  58. - BasketApiClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5103
  59. - OrderingApiClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5102
  60. - MobileShoppingAggClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5120
  61. - WebShoppingAggClient=http://${ESHOP_EXTERNAL_DNS_NAME_OR_IP}:5120
  62. - UseCustomizationData=True
  63. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  64. - OrchestratorType=${ORCHESTRATOR_TYPE}
  65. ports:
  66. - "5105:80"
  67. ordering.api:
  68. environment:
  69. - ASPNETCORE_ENVIRONMENT=Development
  70. - ASPNETCORE_URLS=http://0.0.0.0:80
  71. - ConnectionString=${ESHOP_AZURE_ORDERING_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word}
  72. - identityUrl=http://identity.api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  73. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  74. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  75. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  76. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  77. - UseCustomizationData=True
  78. - AzureServiceBusEnabled=False
  79. - CheckUpdateTime=30000
  80. - GracePeriodTime=1
  81. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  82. - OrchestratorType=${ORCHESTRATOR_TYPE}
  83. - UseLoadTest=${USE_LOADTEST:-False}
  84. ports:
  85. - "5102:80"
  86. marketing.api:
  87. environment:
  88. - ASPNETCORE_ENVIRONMENT=Development
  89. - ASPNETCORE_URLS=http://0.0.0.0:80
  90. - ConnectionString=${ESHOP_AZURE_MARKETING_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Services.MarketingDb;User Id=sa;Password=Pass@word}
  91. - MongoConnectionString=${ESHOP_AZURE_COSMOSDB:-mongodb://nosql.data}
  92. - MongoDatabase=MarketingDb
  93. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  94. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  95. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  96. - identityUrl=http://identity.api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  97. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  98. - CampaignDetailFunctionUri=${ESHOP_AZUREFUNC_CAMPAIGN_DETAILS_URI}
  99. - PicBaseUrl=${ESHOP_AZURE_STORAGE_MARKETING_URL:-http://localhost:5110/api/v1/campaigns/[0]/pic/}
  100. - AzureStorageAccountName=${ESHOP_AZURE_STORAGE_MARKETING_NAME}
  101. - AzureStorageAccountKey=${ESHOP_AZURE_STORAGE_MARKETING_KEY}
  102. - AzureServiceBusEnabled=False
  103. - AzureStorageEnabled=False
  104. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  105. - OrchestratorType=${ORCHESTRATOR_TYPE}
  106. - UseLoadTest=${USE_LOADTEST:-False}
  107. ports:
  108. - "5110:80"
  109. webspa:
  110. environment:
  111. - ASPNETCORE_ENVIRONMENT=Development
  112. - ASPNETCORE_URLS=http://0.0.0.0:80
  113. - CatalogUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5101
  114. - OrderingUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5102
  115. - IdentityUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105 #Local: You need to open your local dev-machine firewall at range 5100-5105. at range 5100-5105.
  116. - BasketUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5103
  117. - MarketingUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5110
  118. - LocationsUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5109
  119. - CatalogUrlHC=http://catalog.api/hc
  120. - OrderingUrlHC=http://ordering.api/hc
  121. - IdentityUrlHC=http://identity.api/hc
  122. - BasketUrlHC=http://basket.api/hc
  123. - MarketingUrlHC=http://marketing.api/hc
  124. - PaymentUrlHC=http://payment.api/hc
  125. - UseCustomizationData=True
  126. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  127. - OrchestratorType=${ORCHESTRATOR_TYPE}
  128. ports:
  129. - "5104:80"
  130. webmvc:
  131. environment:
  132. - ASPNETCORE_ENVIRONMENT=Development
  133. - ASPNETCORE_URLS=http://0.0.0.0:80
  134. - PurchaseUrl=http://webshoppingapigw/shopping
  135. - LocationsUrl=http://locations.api
  136. - IdentityUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105 # Local Mac: Use http://docker.for.mac.localhost:5105 || Local Windows: Use 10.0.75.1 in a "Docker for Windows" environment, if using "localhost" from browser. || #Remote access: Use ${ESHOP_EXTERNAL_DNS_NAME_OR_IP} if using external IP or DNS name from browser.
  137. - MarketingUrl=http://marketing.api
  138. - CatalogUrlHC=http://catalog.api/hc
  139. - OrderingUrlHC=http://ordering.api/hc
  140. - IdentityUrlHC=http://identity.api/hc #Local: Use ${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}, if using external IP or DNS name from browser.
  141. - BasketUrlHC=http://basket.api/hc
  142. - MarketingUrlHC=http://marketing.api/hc
  143. - PaymentUrlHC=http://payment.api/hc
  144. - UseCustomizationData=True
  145. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  146. - OrchestratorType=${ORCHESTRATOR_TYPE}
  147. - UseLoadTest=${USE_LOADTEST:-False}
  148. ports:
  149. - "5100:80"
  150. webstatus:
  151. environment:
  152. - ASPNETCORE_ENVIRONMENT=Development
  153. - ASPNETCORE_URLS=http://0.0.0.0:80
  154. - CatalogUrl=http://catalog.api/hc
  155. - OrderingUrl=http://ordering.api/hc
  156. - BasketUrl=http://basket.api/hc
  157. - IdentityUrl=http://identity.api/hc
  158. - LocationsUrl=http://locations.api/hc
  159. - MarketingUrl=http://marketing.api/hc
  160. - PaymentUrl=http://payment.api/hc
  161. - mvc=http://webmvc/hc
  162. - spa=http://webspa/hc
  163. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  164. - OrchestratorType=${ORCHESTRATOR_TYPE}
  165. ports:
  166. - "5107:80"
  167. payment.api:
  168. environment:
  169. - ASPNETCORE_ENVIRONMENT=Development
  170. - ASPNETCORE_URLS=http://0.0.0.0:80
  171. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  172. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  173. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  174. - AzureServiceBusEnabled=False
  175. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  176. - OrchestratorType=${ORCHESTRATOR_TYPE}
  177. ports:
  178. - "5108:80"
  179. locations.api:
  180. environment:
  181. - ASPNETCORE_ENVIRONMENT=Development
  182. - ASPNETCORE_URLS=http://0.0.0.0:80
  183. - ConnectionString=${ESHOP_AZURE_COSMOSDB:-mongodb://nosql.data}
  184. - Database=LocationsDb
  185. - identityUrl=http://identity.api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  186. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  187. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  188. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  189. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  190. - AzureServiceBusEnabled=False
  191. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  192. - OrchestratorType=${ORCHESTRATOR_TYPE}
  193. - UseLoadTest=${USE_LOADTEST:-False}
  194. ports:
  195. - "5109:80"
  196. sql.data:
  197. environment:
  198. - MSSQL_SA_PASSWORD=Pass@word
  199. - ACCEPT_EULA=Y
  200. - MSSQL_PID=Developer
  201. ports:
  202. - "5433:1433"
  203. nosql.data:
  204. ports:
  205. - "27017:27017"
  206. basket.data:
  207. ports:
  208. - "6379:6379"
  209. rabbitmq:
  210. ports:
  211. - "15672:15672"
  212. - "5672:5672"