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.

247 lines
11 KiB

  1. version: '3.3'
  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. - UseCustomizationData=True
  61. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  62. - OrchestratorType=${ORCHESTRATOR_TYPE}
  63. ports:
  64. - "5105:80"
  65. ordering.api:
  66. environment:
  67. - ASPNETCORE_ENVIRONMENT=Development
  68. - ASPNETCORE_URLS=http://0.0.0.0:80
  69. - ConnectionString=${ESHOP_AZURE_ORDERING_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word}
  70. - identityUrl=http://identity.api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  71. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  72. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  73. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  74. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  75. - UseCustomizationData=True
  76. - AzureServiceBusEnabled=False
  77. - CheckUpdateTime=30000
  78. - GracePeriodTime=1
  79. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  80. - OrchestratorType=${ORCHESTRATOR_TYPE}
  81. - UseLoadTest=${USE_LOADTEST:-False}
  82. ports:
  83. - "5102:80"
  84. ordering.backgroundtasks:
  85. environment:
  86. - ASPNETCORE_ENVIRONMENT=Development
  87. - ASPNETCORE_URLS=http://0.0.0.0:80
  88. - ConnectionString=${ESHOP_AZURE_ORDERING_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word}
  89. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  90. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  91. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  92. - UseCustomizationData=True
  93. - AzureServiceBusEnabled=False
  94. - CheckUpdateTime=30000
  95. - GracePeriodTime=1
  96. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  97. - OrchestratorType=${ORCHESTRATOR_TYPE}
  98. - UseLoadTest=${USE_LOADTEST:-False}
  99. ports:
  100. - "5111:80"
  101. marketing.api:
  102. environment:
  103. - ASPNETCORE_ENVIRONMENT=Development
  104. - ASPNETCORE_URLS=http://0.0.0.0:80
  105. - ConnectionString=${ESHOP_AZURE_MARKETING_DB:-Server=sql.data;Database=Microsoft.eShopOnContainers.Services.MarketingDb;User Id=sa;Password=Pass@word}
  106. - MongoConnectionString=${ESHOP_AZURE_COSMOSDB:-mongodb://nosql.data}
  107. - MongoDatabase=MarketingDb
  108. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  109. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  110. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  111. - identityUrl=http://identity.api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  112. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  113. - CampaignDetailFunctionUri=${ESHOP_AZUREFUNC_CAMPAIGN_DETAILS_URI}
  114. - PicBaseUrl=${ESHOP_AZURE_STORAGE_MARKETING_URL:-http://localhost:5110/api/v1/campaigns/[0]/pic/}
  115. - AzureStorageAccountName=${ESHOP_AZURE_STORAGE_MARKETING_NAME}
  116. - AzureStorageAccountKey=${ESHOP_AZURE_STORAGE_MARKETING_KEY}
  117. - AzureServiceBusEnabled=False
  118. - AzureStorageEnabled=False
  119. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  120. - OrchestratorType=${ORCHESTRATOR_TYPE}
  121. - UseLoadTest=${USE_LOADTEST:-False}
  122. ports:
  123. - "5110:80"
  124. webspa:
  125. environment:
  126. - ASPNETCORE_ENVIRONMENT=Development
  127. - ASPNETCORE_URLS=http://0.0.0.0:80
  128. - CatalogUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5101
  129. - OrderingUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5102
  130. - 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.
  131. - BasketUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5103
  132. - MarketingUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5110
  133. - LocationsUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5109
  134. - CatalogUrlHC=http://catalog.api/hc
  135. - OrderingUrlHC=http://ordering.api/hc
  136. - IdentityUrlHC=http://identity.api/hc
  137. - BasketUrlHC=http://basket.api/hc
  138. - MarketingUrlHC=http://marketing.api/hc
  139. - PaymentUrlHC=http://payment.api/hc
  140. - UseCustomizationData=True
  141. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  142. - OrchestratorType=${ORCHESTRATOR_TYPE}
  143. ports:
  144. - "5104:80"
  145. webmvc:
  146. environment:
  147. - ASPNETCORE_ENVIRONMENT=Development
  148. - ASPNETCORE_URLS=http://0.0.0.0:80
  149. - CatalogUrl=http://catalog.api
  150. - OrderingUrl=http://ordering.api
  151. - BasketUrl=http://basket.api
  152. - LocationsUrl=http://locations.api
  153. - IdentityUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105 #Local: Use 10.0.75.1 in a "Docker for Windows" environment, if using "localhost" from browser. #Remote: Use ${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP} if using external IP or DNS name from browser.
  154. - MarketingUrl=http://marketing.api
  155. - CatalogUrlHC=http://catalog.api/hc
  156. - OrderingUrlHC=http://ordering.api/hc
  157. - IdentityUrlHC=http://identity.api/hc
  158. - BasketUrlHC=http://basket.api/hc
  159. - MarketingUrlHC=http://marketing.api/hc
  160. - PaymentUrlHC=http://payment.api/hc
  161. - UseCustomizationData=True
  162. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  163. - OrchestratorType=${ORCHESTRATOR_TYPE}
  164. - UseLoadTest=${USE_LOADTEST:-False}
  165. ports:
  166. - "5100:80"
  167. webstatus:
  168. environment:
  169. - ASPNETCORE_ENVIRONMENT=Development
  170. - ASPNETCORE_URLS=http://0.0.0.0:80
  171. - CatalogUrl=http://catalog.api/hc
  172. - OrderingUrl=http://ordering.api/hc
  173. - BasketUrl=http://basket.api/hc
  174. - IdentityUrl=http://identity.api/hc
  175. - LocationsUrl=http://locations.api/hc
  176. - MarketingUrl=http://marketing.api/hc
  177. - PaymentUrl=http://payment.api/hc
  178. - mvc=http://webmvc/hc
  179. - spa=http://webspa/hc
  180. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  181. - OrchestratorType=${ORCHESTRATOR_TYPE}
  182. ports:
  183. - "5107:80"
  184. payment.api:
  185. environment:
  186. - ASPNETCORE_ENVIRONMENT=Development
  187. - ASPNETCORE_URLS=http://0.0.0.0:80
  188. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  189. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  190. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  191. - AzureServiceBusEnabled=False
  192. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  193. - OrchestratorType=${ORCHESTRATOR_TYPE}
  194. ports:
  195. - "5108:80"
  196. locations.api:
  197. environment:
  198. - ASPNETCORE_ENVIRONMENT=Development
  199. - ASPNETCORE_URLS=http://0.0.0.0:80
  200. - ConnectionString=${ESHOP_AZURE_COSMOSDB:-mongodb://nosql.data}
  201. - Database=LocationsDb
  202. - identityUrl=http://identity.api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  203. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  204. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  205. - EventBusUserName=${ESHOP_SERVICE_BUS_USERNAME}
  206. - EventBusPassword=${ESHOP_SERVICE_BUS_PASSWORD}
  207. - AzureServiceBusEnabled=False
  208. - ApplicationInsights__InstrumentationKey=${INSTRUMENTATION_KEY}
  209. - OrchestratorType=${ORCHESTRATOR_TYPE}
  210. - UseLoadTest=${USE_LOADTEST:-False}
  211. ports:
  212. - "5109:80"
  213. sql.data:
  214. environment:
  215. - MSSQL_SA_PASSWORD=Pass@word
  216. - ACCEPT_EULA=Y
  217. - MSSQL_PID=Developer
  218. ports:
  219. - "5433:1433"
  220. nosql.data:
  221. ports:
  222. - "27017:27017"
  223. basket.data:
  224. ports:
  225. - "6379:6379"
  226. rabbitmq:
  227. ports:
  228. - "15672:15672"
  229. - "5672:5672"