Browse Source

Added Reverse Proxy LB Rule to ARM template

pull/357/head
Ramón Tomás 7 years ago
parent
commit
e673236bbd
4 changed files with 26 additions and 2 deletions
  1. +4
    -1
      ServiceFabric/eShopOnServiceFabric/ApplicationPackageRoot/ApplicationManifest.xml
  2. +2
    -1
      ServiceFabric/eShopOnServiceFabric/ApplicationParameters/Cloud.xml
  3. +1
    -0
      ServiceFabric/eShopOnServiceFabricWebMVC/eShopOnServiceFabricWebMVC/ApplicationPackageRoot/WebMVCPkg/ServiceManifest.xml
  4. +19
    -0
      deploy/az/servicefabric/WindowsContainers/servicefabricdeploy.json

+ 4
- 1
ServiceFabric/eShopOnServiceFabric/ApplicationPackageRoot/ApplicationManifest.xml View File

@ -19,6 +19,7 @@
<Parameter Name="CatalogApi_InstanceCount" DefaultValue="-1" /> <Parameter Name="CatalogApi_InstanceCount" DefaultValue="-1" />
<Parameter Name="BasketApi_InstanceCount" DefaultValue="-1" /> <Parameter Name="BasketApi_InstanceCount" DefaultValue="-1" />
<Parameter Name="IdentityUrlExternal" DefaultValue="" /> <Parameter Name="IdentityUrlExternal" DefaultValue="" />
<Parameter Name="PicBaseUrl" DefaultValue="" />
</Parameters> </Parameters>
<!-- Import the ServiceManifest from the ServicePackage. The ServiceManifestName and ServiceManifestVersion <!-- Import the ServiceManifest from the ServicePackage. The ServiceManifestName and ServiceManifestVersion
should match the Name and Version attributes of the ServiceManifest element defined in the should match the Name and Version attributes of the ServiceManifest element defined in the
@ -104,7 +105,9 @@
</ServiceManifestImport> </ServiceManifestImport>
<ServiceManifestImport> <ServiceManifestImport>
<ServiceManifestRef ServiceManifestName="CatalogApiPkg" ServiceManifestVersion="1.0.0" /> <ServiceManifestRef ServiceManifestName="CatalogApiPkg" ServiceManifestVersion="1.0.0" />
<ConfigOverrides />
<EnvironmentOverrides CodePackageRef="Code">
<EnvironmentVariable Name="PicBaseUrl" Value="[PicBaseUrl]"/>
</EnvironmentOverrides>
<Policies> <Policies>
<ContainerHostPolicies CodePackageRef="Code"> <ContainerHostPolicies CodePackageRef="Code">
<PortBinding ContainerPort="80" EndpointRef="CatalogApiTypeEndpoint"/> <PortBinding ContainerPort="80" EndpointRef="CatalogApiTypeEndpoint"/>


+ 2
- 1
ServiceFabric/eShopOnServiceFabric/ApplicationParameters/Cloud.xml View File

@ -13,5 +13,6 @@
<Parameter Name="CatalogApi_InstanceCount" Value="-1" /> <Parameter Name="CatalogApi_InstanceCount" Value="-1" />
<Parameter Name="BasketApi_InstanceCount" Value="-1" /> <Parameter Name="BasketApi_InstanceCount" Value="-1" />
<Parameter Name="IdentityUrlExternal" Value="http://your_sf_dns:5105" /> <Parameter Name="IdentityUrlExternal" Value="http://your_sf_dns:5105" />
<Parameter Name="PicBaseUrl" Value="http://your_sf_dns:19081/eShopOnServiceFabric/CatalogApi/api/v1/catalog/items/[0]/pic/" />
</Parameters> </Parameters>
</Application>
</Application>

+ 1
- 0
ServiceFabric/eShopOnServiceFabricWebMVC/eShopOnServiceFabricWebMVC/ApplicationPackageRoot/WebMVCPkg/ServiceManifest.xml View File

@ -27,6 +27,7 @@
<EnvironmentVariable Name="BasketUrl" Value="http://basketapi.eshoponservicefabric:5103"/> <EnvironmentVariable Name="BasketUrl" Value="http://basketapi.eshoponservicefabric:5103"/>
<EnvironmentVariable Name="IdentityUrl" Value=""/> <EnvironmentVariable Name="IdentityUrl" Value=""/>
<EnvironmentVariable Name="MarketingUrl" Value="http://marketingapi.eshoponservicefabric:5110"/> <EnvironmentVariable Name="MarketingUrl" Value="http://marketingapi.eshoponservicefabric:5110"/>
<EnvironmentVariable Name="LocationsUrl" Value="http://locationsapi.eshoponservicefabric:5109"/>
</EnvironmentVariables> </EnvironmentVariables>
</CodePackage> </CodePackage>


+ 19
- 0
deploy/az/servicefabric/WindowsContainers/servicefabricdeploy.json View File

@ -367,6 +367,25 @@
"protocol": "tcp" "protocol": "tcp"
} }
}, },
{
"name": "ReverseProxyHttpRule",
"properties": {
"backendAddressPool": {
"id": "[variables('lbPoolID0')]"
},
"backendPort": "[parameters('nt0reverseProxyEndpointPort')]",
"enableFloatingIP": "false",
"frontendIPConfiguration": {
"id": "[variables('lbIPConfig0')]"
},
"frontendPort": "[parameters('nt0reverseProxyEndpointPort')]",
"idleTimeoutInMinutes": "5",
"probe": {
"id": "[variables('lbHttpProbeID0')]"
},
"protocol": "tcp"
}
},
{ {
"name": "WebMVCHttpRule", "name": "WebMVCHttpRule",
"properties": { "properties": {


Loading…
Cancel
Save