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.

91 lines
3.9 KiB

  1. version: '2'
  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.yml -f docker-compose.prod.yml up -d
  12. services:
  13. basket.api:
  14. environment:
  15. - ASPNETCORE_ENVIRONMENT=Production
  16. - ASPNETCORE_URLS=http://0.0.0.0:5103
  17. - ConnectionString=basket.data
  18. - identityUrl=http://identity.api:5105 #Local: You need to open your host's firewall at range 5100-5105. at range 5100-5105.
  19. ports:
  20. - "5103:5103"
  21. catalog.api:
  22. environment:
  23. - ASPNETCORE_ENVIRONMENT=Production
  24. - ASPNETCORE_URLS=http://0.0.0.0:5101
  25. - ConnectionString=Server=sql.data;Database=Microsoft.eShopOnContainers.Services.CatalogDb;User Id=sa;Password=Pass@word
  26. - ExternalCatalogBaseUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5101 #Local: You need to open your host's firewall at range 5100-5105. at range 5100-5105.
  27. ports:
  28. - "5101:5101"
  29. identity.api:
  30. environment:
  31. - ASPNETCORE_ENVIRONMENT=Production
  32. - ASPNETCORE_URLS=http://0.0.0.0:5105
  33. - SpaClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5104
  34. - ConnectionStrings__DefaultConnection=Server=sql.data;Database=Microsoft.eShopOnContainers.Service.IdentityDb;User Id=sa;Password=Pass@word
  35. - MvcClient=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5100 #Local: You need to open your host's firewall at range 5100-5105.
  36. - XamarinCallback=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105/xamarincallback
  37. ports:
  38. - "5105:5105"
  39. ordering.api:
  40. environment:
  41. - ASPNETCORE_ENVIRONMENT=Production
  42. - ASPNETCORE_URLS=http://0.0.0.0:5102
  43. - ConnectionString=Server=sql.data;Database=Microsoft.eShopOnContainers.Services.OrderingDb;User Id=sa;Password=Pass@word
  44. - identityUrl=http://identity.api:5105 #Local: You need to open your host's firewall at range 5100-5105. at range 5100-5105.
  45. ports:
  46. - "5102:5102"
  47. webspa:
  48. environment:
  49. - ASPNETCORE_ENVIRONMENT=Production
  50. - ASPNETCORE_URLS=http://0.0.0.0:5104
  51. - CatalogUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5101
  52. - OrderingUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5102
  53. - IdentityUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5105 #Local: You need to open your host's firewall at range 5100-5105. at range 5100-5105.
  54. - BasketUrl=http://${ESHOP_PROD_EXTERNAL_DNS_NAME_OR_IP}:5103
  55. ports:
  56. - "5104:5104"
  57. webmvc:
  58. environment:
  59. - ASPNETCORE_ENVIRONMENT=Production
  60. - ASPNETCORE_URLS=http://0.0.0.0:5100
  61. - CatalogUrl=http://catalog.api:5101
  62. - OrderingUrl=http://ordering.api:5102
  63. - 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.
  64. - BasketUrl=http://basket.api:5103
  65. ports:
  66. - "5100:5100"
  67. sql.data:
  68. environment:
  69. - SA_PASSWORD=Pass@word
  70. - ACCEPT_EULA=Y
  71. ports:
  72. - "5433:1433"
  73. webstatus:
  74. environment:
  75. - ASPNETCORE_ENVIRONMENT=Development
  76. - CatalogUrl=http://catalog.api:5101/hc
  77. - OrderingUrl=http://ordering.api:5102/hc
  78. - BasketUrl=http://basket.api:5103/hc
  79. - IdentityUrl=http://10.0.75.1:5105/hc
  80. ports:
  81. - "5107:5107"