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.

140 lines
6.1 KiB

5 years ago
5 years ago
  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. # Set ASPNETCORE_ENVIRONMENT=Development to get errors while testing.
  9. #
  10. # You need to start it with the following CLI command:
  11. # docker-compose -f docker-compose-windows.yml -f docker-compose-windows.prod.yml up -d
  12. services:
  13. basket-api:
  14. environment:
  15. - ASPNETCORE_ENVIRONMENT=Production
  16. - ASPNETCORE_URLS=http://0.0.0.0:80
  17. - ConnectionString=${ESHOP_AZURE_REDIS_BASKET_DB:-basket.data}
  18. - identityUrl=http://identity-api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  19. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  20. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  21. - AzureServiceBusEnabled=False
  22. ports:
  23. - "5103:5103"
  24. catalog-api:
  25. environment:
  26. - ASPNETCORE_ENVIRONMENT=Production
  27. - ASPNETCORE_URLS=http://0.0.0.0:80
  28. - ConnectionString=${ESHOP_AZURE_CATALOG_DB:-Server=sqldata;Database=Microsoft.eShopOnContainers.Services.CatalogDb;User Id=sa;Password=Pass@word}
  29. - PicBaseUrl=${ESHOP_AZURE_STORAGE_CATALOG:-http://localhost:5101/api/v1/catalog/items/[0]/pic/} #Local: You need to open your local dev-machine firewall at range 5100-5110.
  30. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  31. - AzureStorageAccountName=${ESHOP_AZURE_STORAGE_CATALOG_NAME}
  32. - AzureStorageAccountKey=${ESHOP_AZURE_STORAGE_CATALOG_KEY}
  33. - UseCustomizationData=True
  34. - AzureServiceBusEnabled=False
  35. - AzureStorageEnabled=False
  36. ports:
  37. - "5101:80"
  38. identity-api:
  39. environment:
  40. - ASPNETCORE_ENVIRONMENT=Production
  41. - ASPNETCORE_URLS=http://0.0.0.0:80
  42. - SpaClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5104
  43. - XamarinCallback=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105/xamarincallback
  44. - ConnectionStrings__DefaultConnection=${ESHOP_AZURE_IDENTITY_DB:-Server=sqldata;Database=Microsoft.eShopOnContainers.Service.IdentityDb;User Id=sa;Password=Pass@word}
  45. - MvcClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5100 #Local: You need to open your local dev-machine firewall at range 5100-5110.
  46. - BasketApiClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5103
  47. - OrderingApiClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5102
  48. - UseCustomizationData=True
  49. ports:
  50. - "5105:80"
  51. ordering-api:
  52. environment:
  53. - ASPNETCORE_ENVIRONMENT=Production
  54. - ASPNETCORE_URLS=http://0.0.0.0:80
  55. - ConnectionString=${ESHOP_AZURE_ORDERING_DB:-Server=sqldata;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word}
  56. - identityUrl=http://identity-api #Local: You need to open your local dev-machine firewall at range 5100-5110.
  57. - IdentityUrlExternal=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105
  58. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  59. - UseCustomizationData=True
  60. - AzureServiceBusEnabled=False
  61. ports:
  62. - "5102:80"
  63. ordering.backgroundtasks:
  64. environment:
  65. - ASPNETCORE_ENVIRONMENT=Production
  66. - ASPNETCORE_URLS=http://0.0.0.0:80
  67. - ConnectionString=${ESHOP_AZURE_ORDERING_DB:-Server=sqldata;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word}
  68. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  69. - UseCustomizationData=True
  70. - AzureServiceBusEnabled=False
  71. ports:
  72. - "5111:80"
  73. webspa:
  74. environment:
  75. - ASPNETCORE_ENVIRONMENT=Production
  76. - ASPNETCORE_URLS=http://0.0.0.0
  77. - CatalogUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5101
  78. - OrderingUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5102
  79. - IdentityUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105 #Local: You need to open your host's firewall at range 5100-5110.
  80. - BasketUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5103
  81. - CatalogUrlHC=http://catalog-api/hc
  82. - OrderingUrlHC=http://ordering-api/hc
  83. - IdentityUrlHC=http://identity-api/hc #Local: Use ${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}, if using external IP or DNS name from browser.
  84. - BasketUrlHC=http://basket-api/hc
  85. - UseCustomizationData=True
  86. ports:
  87. - "5104:80"
  88. webmvc:
  89. environment:
  90. - ASPNETCORE_ENVIRONMENT=Production
  91. - ASPNETCORE_URLS=http://0.0.0.0:80
  92. - CatalogUrl=http://catalog-api
  93. - OrderingUrl=http://ordering-api
  94. - IdentityUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105 #Local: Use ${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}, if using external IP or DNS name from browser.
  95. - BasketUrl=http://basket-api
  96. - UseCustomizationData=True #Remote: Use ${ESHOP_EXTERNAL_DNS_NAME_OR_IP} if using external IP or DNS name from browser.
  97. ports:
  98. - "5100:80"
  99. sqldata:
  100. environment:
  101. - MSSQL_SA_PASSWORD=Pass@word
  102. - ACCEPT_EULA=Y
  103. ports:
  104. - "5433:1433"
  105. nosqldata:
  106. ports:
  107. - "27017:27017"
  108. webstatus:
  109. environment:
  110. - ASPNETCORE_ENVIRONMENT=Production
  111. - ASPNETCORE_URLS=http://0.0.0.0:80
  112. - CatalogUrl=http://catalog-api/hc
  113. - OrderingUrl=http://ordering-api/hc
  114. - BasketUrl=http://basket-api/hc
  115. - IdentityUrl=http://identity-api/hc
  116. - mvc=http://webmvc/hc
  117. - spa=http://webspa/hc
  118. ports:
  119. - "5107:80"
  120. payment-api:
  121. environment:
  122. - ASPNETCORE_ENVIRONMENT=Production
  123. - ASPNETCORE_URLS=http://0.0.0.0:5108
  124. - EventBusConnection=${ESHOP_AZURE_SERVICE_BUS:-rabbitmq}
  125. - AzureServiceBusEnabled=False
  126. ports:
  127. - "5108:80"