diff --git a/reference-apps/eshop/iac/services/basket.bicep b/reference-apps/eshop/iac/services/basket.bicep index 58aaeff8..9a7cdb4a 100644 --- a/reference-apps/eshop/iac/services/basket.bicep +++ b/reference-apps/eshop/iac/services/basket.bicep @@ -27,15 +27,6 @@ param ORCHESTRATOR_TYPE string @description('The name of the Radius Gateway') param gatewayName string -@description('The name of the Identity HTTP Route') -param identityHttpName string - -@description('The name of the Basket HTTP Route') -param basketHttpName string - -@description('The name of the Basket gRPC Route') -param basketGrpcName string - @description('The name of the Redis Basket portable resource') param redisBasketName string @@ -67,17 +58,17 @@ resource basket 'Applications.Core/containers@2022-03-15-privatepreview' = { AzureServiceBusEnabled: AZURESERVICEBUSENABLED ConnectionString: redisBasket.connectionString() EventBusConnection: (AZURESERVICEBUSENABLED == 'True') ? serviceBusConnectionString : rabbitmq.properties.host - identityUrl: identityHttp.properties.url - IdentityUrlExternal: '${gateway.properties.url}/${identityHttp.properties.hostname}' + identityUrl: 'http://identity-api:5105' + IdentityUrlExternal: '${gateway.properties.url}/identity-api' } ports: { http: { containerPort: 80 - provides: basketHttp.id + port: 5103 } grpc: { containerPort: 81 - provides: basketGrpc.id + port: 9103 } } } @@ -87,7 +78,7 @@ resource basket 'Applications.Core/containers@2022-03-15-privatepreview' = { disableDefaultEnvVars: true } identity: { - source: identityHttp.id + source: 'http://identity-api:5105' disableDefaultEnvVars: true } } @@ -100,18 +91,6 @@ resource gateway 'Applications.Core/gateways@2022-03-15-privatepreview' existing name: gatewayName } -resource identityHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: identityHttpName -} - -resource basketHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: basketHttpName -} - -resource basketGrpc 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: basketGrpcName -} - // Portable Resource ------------------------------------------ resource redisBasket 'Applications.Datastores/redisCaches@2022-03-15-privatepreview' existing = { @@ -121,3 +100,7 @@ resource redisBasket 'Applications.Datastores/redisCaches@2022-03-15-privateprev resource rabbitmq 'Applications.Messaging/rabbitMQQueues@2022-03-15-privatepreview' existing = { name: rabbitmqName } + +// Output +@description('Name of the Basket container') +output container string = basket.name diff --git a/reference-apps/eshop/iac/services/catalog.bicep b/reference-apps/eshop/iac/services/catalog.bicep index 0ae9712b..ec3a6bd6 100644 --- a/reference-apps/eshop/iac/services/catalog.bicep +++ b/reference-apps/eshop/iac/services/catalog.bicep @@ -34,12 +34,6 @@ param TAG string @description('Name of the Gateway') param gatewayName string -@description('The name of the Catalog HTTP Route') -param catalogHttpName string - -@description('The name of the Catalog gRPC Route') -param catalogGrpcName string - @description('The name of the RabbitMQ portable resource') param rabbitmqName string @@ -79,11 +73,11 @@ resource catalog 'Applications.Core/containers@2022-03-15-privatepreview' = { ports: { http: { containerPort: 80 - provides: catalogHttp.id + port: 5101 } grpc: { containerPort: 81 - provides: catalogGrpc.id + port: 9101 } } } @@ -101,13 +95,6 @@ resource gateway 'Applications.Core/gateways@2022-03-15-privatepreview' existing name: gatewayName } -resource catalogHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: catalogHttpName -} - -resource catalogGrpc 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: catalogGrpcName -} // PORTABLE RESOURCES ----------------------------------------------------------- @@ -118,3 +105,8 @@ resource sqlCatalogDb 'Applications.Datastores/sqlDatabases@2022-03-15-privatepr resource rabbitmq 'Applications.Messaging/rabbitMQQueues@2022-03-15-privatepreview' existing = { name: rabbitmqName } + + +// Output +@description('Name of the Catalog container') +output container string = catalog.name diff --git a/reference-apps/eshop/iac/services/identity.bicep b/reference-apps/eshop/iac/services/identity.bicep index 58e515bb..ab54ef14 100644 --- a/reference-apps/eshop/iac/services/identity.bicep +++ b/reference-apps/eshop/iac/services/identity.bicep @@ -21,25 +21,22 @@ param TAG string @description('Name of the Gateway') param gatewayName string -@description('Name of the Identity HTTP Route') -param identityHttpName string - -@description('Name of the Basket HTTP Route') +@description('Name of the Basket Container') param basketHttpName string -@description('Name of the Ordering HTTP Route') +@description('Name of the Ordering Container') param orderingHttpName string -@description('Name of the WebShoppingAgg HTTP Route') +@description('Name of the WebShoppingAgg Container') param webshoppingaggHttpName string -@description('Name of the Webhooks HTTP Route') +@description('Name of the Webhooks Container') param webhooksHttpName string -@description('Name of the WebhooksClient HTTP Route') +@description('Name of the WebhooksClient Container') param webhooksclientHttpName string -@description('Name of the WebMVC HTTP Route') +@description('Name of the WebMVC Container') param webmvcHttpName string @description('Name of the Identity SQL Database portable resource') @@ -68,18 +65,18 @@ resource identity 'Applications.Core/containers@2022-03-15-privatepreview' = { XamarinCallback: '' EnableDevspaces: ENABLEDEVSPACES ConnectionString: sqlIdentityDb.connectionString() - MvcClient: '${gateway.properties.url}/${webmvcHttp.properties.hostname}' + MvcClient: '${gateway.properties.url}/${webmvcHttp.name}' SpaClient: gateway.properties.url - BasketApiClient: '${gateway.properties.url}/${basketHttp.properties.hostname}' - OrderingApiClient: '${gateway.properties.url}/${orderingHttp.properties.hostname}' - WebShoppingAggClient: '${gateway.properties.url}/${webshoppingaggHttp.properties.hostname}' - WebhooksApiClient: '${gateway.properties.url}/${webhooksHttp.properties.hostname}' - WebhooksWebClient: '${gateway.properties.url}/${webhooksclientHttp.properties.hostname}' + BasketApiClient: '${gateway.properties.url}/${basketHttp.name}' + OrderingApiClient: '${gateway.properties.url}/${orderingHttp.name}' + WebShoppingAggClient: '${gateway.properties.url}/${webshoppingaggHttp.name}' + WebhooksApiClient: '${gateway.properties.url}/${webhooksHttp.name}' + WebhooksWebClient: '${gateway.properties.url}/${webhooksclientHttp.name}' } ports: { http: { containerPort: 80 - provides: identityHttp.id + port: 5105 } } } @@ -126,31 +123,27 @@ resource gateway 'Applications.Core/gateways@2022-03-15-privatepreview' existing name: gatewayName } -resource identityHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: identityHttpName -} - -resource basketHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { +resource basketHttp 'Applications.Core/containers@2022-03-15-privatepreview' existing = { name: basketHttpName } -resource orderingHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { +resource orderingHttp 'Applications.Core/containers@2022-03-15-privatepreview' existing = { name: orderingHttpName } -resource webshoppingaggHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { +resource webshoppingaggHttp 'Applications.Core/containers@2022-03-15-privatepreview' existing = { name: webshoppingaggHttpName } -resource webhooksHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { +resource webhooksHttp 'Applications.Core/containers@2022-03-15-privatepreview' existing = { name: webhooksHttpName } -resource webhooksclientHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { +resource webhooksclientHttp 'Applications.Core/containers@2022-03-15-privatepreview' existing = { name: webhooksclientHttpName } -resource webmvcHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { +resource webmvcHttp 'Applications.Core/containers@2022-03-15-privatepreview' existing = { name: webmvcHttpName } @@ -163,3 +156,8 @@ resource sqlIdentityDb 'Applications.Datastores/sqlDatabases@2022-03-15-privatep resource redisKeystore 'Applications.Datastores/redisCaches@2022-03-15-privatepreview' existing = { name: redisKeystoreName } + + +// Output +@description('Name of the Identity container') +output container string = identity.name diff --git a/reference-apps/eshop/iac/services/networking.bicep b/reference-apps/eshop/iac/services/networking.bicep index 2ceb05d3..d3aea063 100644 --- a/reference-apps/eshop/iac/services/networking.bicep +++ b/reference-apps/eshop/iac/services/networking.bicep @@ -13,263 +13,49 @@ resource gateway 'Applications.Core/gateways@2022-03-15-privatepreview' = { routes: [ { path: '/identity-api' - destination: identityHttp.id + destination: 'http://identity-api' } { path: '/ordering-api' - destination: orderingHttp.id + destination: 'http://ordering-api' } { path: '/basket-api' - destination: basketHttp.id + destination: 'http://basket-api' } { path: '/webhooks-api' - destination: webhooksHttp.id + destination: 'http://webhooks-api' } { path: '/webshoppingagg' - destination: webshoppingaggHttp.id + destination: 'http://webshoppingagg' } { path: '/webshoppingapigw' - destination: webshoppingapigwHttp.id + destination: 'http://webshoppingapigw' } { path: '/webhooks-web' - destination: webhooksclientHttp.id + destination: 'http://webhooks-client' } { path: '/webstatus' - destination: webstatusHttp.id + destination: 'http://webstatus' } { path: '/' - destination: webspaHttp.id + destination: 'http://web-spa' } { path: '/webmvc' - destination: webmvcHttp.id + destination: 'http://webmvc' } ] } } - -// ROUTES ---------------------------------------------------------- - -resource basketHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'basket-http' - properties: { - application: application - port: 5103 - } -} - -resource basketGrpc 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'basket-grpc' - properties: { - application: application - port: 9103 - } -} - -resource catalogHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'catalog-http' - properties: { - application: application - port: 5101 - } -} - -resource catalogGrpc 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'catalog-grpc' - properties: { - application: application - port: 9101 - } -} - -resource identityHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'identity-http' - properties: { - application: application - port: 5105 - } -} - -resource orderingHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'ordering-http' - properties: { - application: application - port: 5102 - } -} - -resource orderingGrpc 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'ordering-grpc' - properties: { - application: application - port: 9102 - } -} - -resource orderingsignalrhubHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'orderingsignalrhub-http' - properties: { - application: application - port: 5112 - } -} - -resource orderbgtasksHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'orderbgtasks-http' - properties: { - application: application - port: 5111 - } -} - -resource paymentHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'payment-http' - properties: { - application: application - port: 5108 - } -} - -resource seqHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'seq-http' - properties: { - application: application - port: 5340 - } -} - -resource webspaHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'webspa-http' - properties: { - application: application - port: 5104 - } -} - -resource webmvcHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'webmvc-http' - properties: { - application: application - port: 5100 - } -} - -resource webhooksHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'webhooks-http' - properties: { - application: application - port: 5113 - } -} - -resource webhooksclientHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'webhooksclient-http' - properties: { - application: application - port: 5114 - hostname: '/webhooks-web' - } -} - -resource webshoppingaggHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'webshoppingagg-http' - properties: { - application: application - port: 5121 - } -} - -resource webshoppingapigwHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'webshoppingapigw-http' - properties: { - application: application - port: 5202 - } -} - -resource webshoppingapigwHttp2 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'webshoppingapigw-http-2' - properties: { - application: application - port: 15202 - } -} - -resource webstatusHttp 'Applications.Core/httproutes@2022-03-15-privatepreview' = { - name: 'webstatus-http' - properties: { - application: application - port: 8107 - } -} - // OUTPUTS -------------------------------------------------------------------- @description('Name of the Gateway') -output gateway string = gateway.name - -@description('Name of the Basket HTTP route') -output basketHttp string = basketHttp.name - -@description('Name of the Basket gRPC route') -output basketGrpc string = basketGrpc.name - -@description('Name of the Catalog HTTP route') -output catalogHttp string = catalogHttp.name - -@description('Name of the Catalog gRPC route') -output catalogGrpc string = catalogGrpc.name - -@description('Name of the Identity HTTP route') -output identityHttp string = identityHttp.name - -@description('Name of the Ordering HTTP route') -output orderingHttp string = orderingHttp.name - -@description('Name of the Ordering gRPC route') -output orderingGrpc string = orderingGrpc.name - -@description('Name of the Ordering SignalR Hub HTTP route') -output orderingsignalrhubHttp string = orderingsignalrhubHttp.name - -@description('Name of the Ordering Background Tasks HTTP route') -output orderbgtasksHttp string = orderbgtasksHttp.name - -@description('Name of the Payment HTTP route') -output paymentHttp string = paymentHttp.name - -@description('Name of the SEQ HTTP route') -output seqHttp string = seqHttp.name - -@description('Name of the WebSPA HTTP route') -output webspaHttp string = webspaHttp.name - -@description('Name of the WebMVC HTTP route') -output webmvcHttp string = webmvcHttp.name - -@description('Name of the Webhooks HTTP route') -output webhooksHttp string = webhooksHttp.name - -@description('Name of the Webhooks Client HTTP route') -output webhooksclientHttp string = webhooksclientHttp.name - -@description('Name of the WebShopping Aggregator HTTP route') -output webshoppingaggHttp string = webshoppingaggHttp.name - -@description('Name of the WebShopping API Gateway HTTP route') -output webshoppingapigwHttp string = webshoppingapigwHttp.name - -@description('Name of the WebShopping API Gateway HTTP route') -output webshoppingapigwHttp2 string = webshoppingapigwHttp2.name - -@description('Name of the WebStatus HTTP route') -output webstatusHttp string = webstatusHttp.name - +output gateway string = gateway.name \ No newline at end of file diff --git a/reference-apps/eshop/iac/services/ordering.bicep b/reference-apps/eshop/iac/services/ordering.bicep index 94a83720..1a29104a 100644 --- a/reference-apps/eshop/iac/services/ordering.bicep +++ b/reference-apps/eshop/iac/services/ordering.bicep @@ -27,27 +27,6 @@ param TAG string @description('Name of the Gateway') param gatewayName string -@description('Name of the Identity HTTP Route') -param identityHttpName string - -@description('Name of the Basket HTTP Route') -param basketHttpName string - -@description('The name of the Catalog HTTP Route') -param catalogHttpName string - -@description('Name of the Ordering HTTP Route') -param orderingHttpName string - -@description('Name of the Ordering gRPC Route') -param orderingGrpcName string - -@description('Name of the Ordering SignalR Hub HTTP Route') -param orderingsignalrhubHttpName string - -@description('Name of the Ordering background tasks HTTP Route') -param orderbgtasksHttpName string - @description('Name of the Keystore Redis portable resource') param redisKeystoreName string @@ -86,17 +65,17 @@ resource ordering 'Applications.Core/containers@2022-03-15-privatepreview' = { PORT: '80' ConnectionString: sqlOrderingDb.connectionString() EventBusConnection: (AZURESERVICEBUSENABLED == 'True') ? serviceBusConnectionString : rabbitmq.properties.host - identityUrl: identityHttp.properties.url - IdentityUrlExternal: '${gateway.properties.url}/${identityHttp.properties.hostname}' + identityUrl: 'http://identity-api:5105' + IdentityUrlExternal: '${gateway.properties.url}/identity-api' } ports: { http: { containerPort: 80 - provides: orderingHttp.id + port: 5102 } grpc: { containerPort: 81 - provides: orderingGrpc.id + port: 9102 } } } @@ -106,7 +85,7 @@ resource ordering 'Applications.Core/containers@2022-03-15-privatepreview' = { disableDefaultEnvVars: true } identity: { - source: identityHttp.id + source: 'http://identity-api:5105' disableDefaultEnvVars: true } } @@ -137,7 +116,7 @@ resource orderbgtasks 'Applications.Core/containers@2022-03-15-privatepreview' = ports: { http: { containerPort: 80 - provides: orderbgtasksHttp.id + port: 5111 } } } @@ -167,13 +146,13 @@ resource orderingsignalrhub 'Applications.Core/containers@2022-03-15-privateprev AzureServiceBusEnabled: AZURESERVICEBUSENABLED EventBusConnection: (AZURESERVICEBUSENABLED == 'True') ? serviceBusConnectionString : rabbitmq.properties.host SignalrStoreConnectionString: '${redisKeystore.properties.host}:${redisKeystore.properties.port},password=${redisKeystore.password()},abortConnect=False' - identityUrl: identityHttp.properties.url - IdentityUrlExternal: '${gateway.properties.url}/${identityHttp.properties.hostname}' + identityUrl: 'http://identity-api:5105' + IdentityUrlExternal: '${gateway.properties.url}/identity-api' } ports: { http: { containerPort: 80 - provides: orderingsignalrhubHttp.id + port: 5112 } } } @@ -183,19 +162,19 @@ resource orderingsignalrhub 'Applications.Core/containers@2022-03-15-privateprev disableDefaultEnvVars: true } identity: { - source: identityHttp.id + source: 'http://identity-api:5105' disableDefaultEnvVars: true } ordering: { - source: orderingHttp.id + source: 'http://ordering-api:5102' disableDefaultEnvVars: true } catalog: { - source: catalogHttp.id + source: 'http://catalog-api:5101' disableDefaultEnvVars: true } basket: { - source: basketHttp.id + source: 'http://basket-api:5103' disableDefaultEnvVars: true } } @@ -208,34 +187,6 @@ resource gateway 'Applications.Core/gateways@2022-03-15-privatepreview' existing name: gatewayName } -resource identityHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: identityHttpName -} - -resource basketHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: basketHttpName -} - -resource catalogHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: catalogHttpName -} - -resource orderingHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: orderingHttpName -} - -resource orderingGrpc 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: orderingGrpcName -} - -resource orderingsignalrhubHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: orderingsignalrhubHttpName -} - -resource orderbgtasksHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: orderbgtasksHttpName -} - // PORTABLE RESOURCES ----------------------------------------------------------- resource redisKeystore 'Applications.Datastores/redisCaches@2022-03-15-privatepreview' existing = { @@ -249,3 +200,15 @@ resource sqlOrderingDb 'Applications.Datastores/sqlDatabases@2022-03-15-privatep resource rabbitmq 'Applications.Messaging/rabbitMQQueues@2022-03-15-privatepreview' existing = { name: rabbitmqName } + + +// Output +@description('Name of the Ordering container') +output apiContainer string = ordering.name +@description('Name of the Ordering Background tasks container') +output bgContainer string = orderbgtasks.name + +@description('Name of the Ordering signal rhub') +output sigContainer string = orderingsignalrhub.name + + diff --git a/reference-apps/eshop/iac/services/payment.bicep b/reference-apps/eshop/iac/services/payment.bicep index 03448ea4..6b45152b 100644 --- a/reference-apps/eshop/iac/services/payment.bicep +++ b/reference-apps/eshop/iac/services/payment.bicep @@ -24,9 +24,6 @@ param AZURESERVICEBUSENABLED string @description('Cotnainer image tag to use for eshop images') param TAG string -@description('Name of the Payment HTTP route') -param paymentHttpName string - @description('The name of the RabbitMQ portable resource') param rabbitmqName string @@ -54,21 +51,20 @@ resource payment 'Applications.Core/containers@2022-03-15-privatepreview' = { ports: { http: { containerPort: 80 - provides: paymentHttp.id + port: 5108 } } } } } -// NETWORKING ------------------------------------------------------ - -resource paymentHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: paymentHttpName -} - // PORTABLE RESOURCES ----------------------------------------------------------- resource rabbitmq 'Applications.Messaging/rabbitMQQueues@2022-03-15-privatepreview' existing = { name: rabbitmqName } + + +// Output +@description('Name of the Payment container') +output container string = payment.name diff --git a/reference-apps/eshop/iac/services/seq.bicep b/reference-apps/eshop/iac/services/seq.bicep index b8074b9f..dbc2fc86 100644 --- a/reference-apps/eshop/iac/services/seq.bicep +++ b/reference-apps/eshop/iac/services/seq.bicep @@ -5,9 +5,6 @@ import radius as rad @description('Radius application ID') param application string -@description('Name of the SEQ Http Route') -param seqHttpName string - // CONTAINERS ------------------------------------------------------------ resource seq 'Applications.Core/containers@2022-03-15-privatepreview' = { @@ -22,15 +19,14 @@ resource seq 'Applications.Core/containers@2022-03-15-privatepreview' = { ports: { web: { containerPort: 80 - provides: seqHttp.id + port: 5340 } } } } } -// NETWORKING --------------------------------------------------------------- -resource seqHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: seqHttpName -} +// Output +@description('Name of the SEQ container') +output container string = seq.name diff --git a/reference-apps/eshop/iac/services/web.bicep b/reference-apps/eshop/iac/services/web.bicep index de1cb7e6..f642790a 100644 --- a/reference-apps/eshop/iac/services/web.bicep +++ b/reference-apps/eshop/iac/services/web.bicep @@ -20,24 +20,6 @@ param TAG string @description('Name of the Gateway') param gatewayName string -@description('Ordering SignalR Hub Http Route name') -param orderingsignalrhubHttpName string - -@description('Identity Http Route name') -param identityHttpName string - -@description('Web MVC Http Route name') -param webmvcHttpName string - -@description('Web SPA Http Route name') -param webspaHttpName string - -@description('Web Shopping Aggregator Http Route name') -param webshoppingaggHttpName string - -@description('Web shopping API GW HTTP Route name') -param webshoppingapigwHttpName string - @description('Name of the Keystore Redis portable resource') param redisKeystoreName string @@ -61,14 +43,14 @@ resource webspa 'Applications.Core/containers@2022-03-15-privatepreview' = { CallBackUrl: '${gateway.properties.url}/' DPConnectionString: redisKeystore.connectionString() IdentityUrl: '${gateway.properties.url}/identity-api' - IdentityUrlHC: '${identityHttp.properties.url}/hc' + IdentityUrlHC: 'http://identity-api:5105/hc' PurchaseUrl: '${gateway.properties.url}/webshoppingapigw' - SignalrHubUrl: orderingsignalrhubHttp.properties.url + SignalrHubUrl: 'http://ordering-signalrhub:5112' } ports: { http: { containerPort: 80 - provides: webspaHttp.id + port: 5104 } } } @@ -78,19 +60,19 @@ resource webspa 'Applications.Core/containers@2022-03-15-privatepreview' = { disableDefaultEnvVars: true } webshoppingagg: { - source: webshoppingaggHttp.id + source: 'http://webshoppingagg:5121' disableDefaultEnvVars: true } identity: { - source: identityHttp.id + source: 'http://identity-api:5105' disableDefaultEnvVars: true } webshoppingapigw: { - source: webshoppingapigwHttp.id + source: 'http://webshoppingapigw:5202' disableDefaultEnvVars: true } orderingsignalrhub: { - source: orderingsignalrhubHttp.id + source: 'http://ordering-signalrhub:5112' disableDefaultEnvVars: true } } @@ -114,17 +96,17 @@ resource webmvc 'Applications.Core/containers@2022-03-15-privatepreview' = { UseLoadTest: 'False' OrchestratorType: ORCHESTRATOR_TYPE IsClusterEnv: 'True' - ExternalPurchaseUrl: '${gateway.properties.url}/${webshoppingapigwHttp.properties.hostname}' + ExternalPurchaseUrl: '${gateway.properties.url}/webshoppingapigw' CallBackUrl: '${gateway.properties.url}/webmvc' IdentityUrl: '${gateway.properties.url}/identity-api' - IdentityUrlHC: '${identityHttp.properties.url}/hc' - PurchaseUrl: webshoppingapigwHttp.properties.url - SignalrHubUrl: orderingsignalrhubHttp.properties.url + IdentityUrlHC: 'http://identity-api:5105/hc' + PurchaseUrl: 'http://webshoppingapigw:5202' + SignalrHubUrl: 'http://ordering-signalrhub:5112' } ports: { http: { containerPort: 80 - provides: webmvcHttp.id + port: 5100 } } } @@ -134,19 +116,19 @@ resource webmvc 'Applications.Core/containers@2022-03-15-privatepreview' = { disableDefaultEnvVars: true } webshoppingagg: { - source: webshoppingaggHttp.id + source: 'http://webshoppingagg:5121' disableDefaultEnvVars: true } identity: { - source: identityHttp.id + source: 'http://identity-api:5105' disableDefaultEnvVars: true } webshoppingapigw: { - source: webshoppingapigwHttp.id + source: 'http://webshoppingapigw:5202' disableDefaultEnvVars: true } orderingsignalrhub: { - source: orderingsignalrhubHttp.id + source: 'http://ordering-signalrhub:5112' disableDefaultEnvVars: true } } @@ -159,32 +141,16 @@ resource gateway 'Applications.Core/gateways@2022-03-15-privatepreview' existing name: gatewayName } -resource orderingsignalrhubHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: orderingsignalrhubHttpName -} - -resource identityHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: identityHttpName -} - -resource webmvcHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: webmvcHttpName -} - -resource webspaHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: webspaHttpName -} - -resource webshoppingaggHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: webshoppingaggHttpName -} - -resource webshoppingapigwHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: webshoppingapigwHttpName -} - // PORTABLE RESOURCES ------------------------------------------------------ resource redisKeystore 'Applications.Datastores/redisCaches@2022-03-15-privatepreview' existing = { name: redisKeystoreName } + + +// Output +@description('Name of the Web spa container') +output spacontainer string = webspa.name + +@description('Name of the Web mvc container') +output mvccontainer string = webmvc.name diff --git a/reference-apps/eshop/iac/services/webhooks.bicep b/reference-apps/eshop/iac/services/webhooks.bicep index dd1fbdc3..347baeab 100644 --- a/reference-apps/eshop/iac/services/webhooks.bicep +++ b/reference-apps/eshop/iac/services/webhooks.bicep @@ -24,15 +24,6 @@ param TAG string @description('Name of the Gateway') param gatewayName string -@description('Name of the Identity HTTP Route') -param identityHttpName string - -@description('Name of the Webhooks HTTP Route') -param webhooksHttpName string - -@description('Name of the WebhooksClient HTTP Route') -param webhooksclientHttpName string - @description('The name of the Webhooks SQL portable resource') param sqlWebhooksDbName string @@ -60,13 +51,13 @@ resource webhooks 'Applications.Core/containers@2022-03-15-privatepreview' = { AzureServiceBusEnabled: AZURESERVICEBUSENABLED ConnectionString: sqlWebhooksDb.connectionString() EventBusConnection: (AZURESERVICEBUSENABLED == 'True') ? serviceBusConnectionString : rabbitmq.properties.host - identityUrl: identityHttp.properties.url - IdentityUrlExternal: '${gateway.properties.url}/${identityHttp.properties.hostname}' + identityUrl: 'http://identity-api:5105' + IdentityUrlExternal: '${gateway.properties.url}/identity-api' } ports: { http: { containerPort: 80 - provides: webhooksHttp.id + port: 5113 } } } @@ -76,7 +67,7 @@ resource webhooks 'Applications.Core/containers@2022-03-15-privatepreview' = { disableDefaultEnvVars: true } identity: { - source: identityHttp.id + source: 'http://identity-api:5105' disableDefaultEnvVars: true } } @@ -96,24 +87,24 @@ resource webhooksclient 'Applications.Core/containers@2022-03-15-privatepreview' ASPNETCORE_URLS: 'http://0.0.0.0:80' PATH_BASE: '/webhooks-web' Token: 'WebHooks-Demo-Web' - CallBackUrl: '${gateway.properties.url}/${webhooksclientHttp.properties.hostname}' - SelfUrl: webhooksclientHttp.properties.url - WebhooksUrl: webhooksHttp.properties.url - IdentityUrl: '${gateway.properties.url}/${identityHttp.properties.hostname}' + CallBackUrl: '${gateway.properties.url}/webhooks-client' + SelfUrl: 'http://webhooks-client:5114' + WebhooksUrl: 'http://webhooks-api:5113' + IdentityUrl: '${gateway.properties.url}/identity-api' } ports: { http: { containerPort: 80 - provides: webhooksclientHttp.id + port: 5114 } } } connections: { webhooks: { - source: webhooksHttp.id + source: 'http://webhooks-api:5113' } identity: { - source: identityHttp.id + source: 'http://identity-api:5105' } } } @@ -125,18 +116,6 @@ resource gateway 'Applications.Core/gateways@2022-03-15-privatepreview' existing name: gatewayName } -resource identityHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: identityHttpName -} - -resource webhooksHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: webhooksHttpName -} - -resource webhooksclientHttp 'Applications.Core/httpRoutes@2022-03-15-privatepreview' existing = { - name: webhooksclientHttpName -} - // PORTABLE RESOURCES ----------------------------------------------------------- resource sqlWebhooksDb 'Applications.Datastores/sqlDatabases@2022-03-15-privatepreview' existing = { diff --git a/reference-apps/eshop/iac/services/webshopping.bicep b/reference-apps/eshop/iac/services/webshopping.bicep index 4571a273..a87ce515 100644 --- a/reference-apps/eshop/iac/services/webshopping.bicep +++ b/reference-apps/eshop/iac/services/webshopping.bicep @@ -83,7 +83,7 @@ resource webshoppingagg 'Applications.Core/containers@2022-03-15-privatepreview' ports: { http: { containerPort: 80 - provides: webshoppingaggHttp.id + port: 5121 } } } @@ -123,11 +123,11 @@ resource webshoppingapigw 'Applications.Core/containers@2022-03-15-privateprevie ports: { http: { containerPort: 80 - provides: webshoppingapigwHttp.id + port: 5202 } http2: { containerPort: 8001 - provides: webshoppingapigwHttp2.id + port: 15202 } } } diff --git a/reference-apps/eshop/iac/services/webstatus.bicep b/reference-apps/eshop/iac/services/webstatus.bicep index 36877715..b27459bb 100644 --- a/reference-apps/eshop/iac/services/webstatus.bicep +++ b/reference-apps/eshop/iac/services/webstatus.bicep @@ -88,7 +88,7 @@ resource webstatus 'Applications.Core/containers@2022-03-15-privatepreview' = { ports: { http: { containerPort: 80 - provides: webstatusHttp.id + port: 8107 } } }