@ -1,24 +0,0 @@ | |||||
FROM mcr.microsoft.com/dotnet/core/aspnet:2.2 AS base | |||||
WORKDIR /app | |||||
EXPOSE 80 | |||||
FROM mcr.microsoft.com/dotnet/core/sdk:2.2 AS build | |||||
WORKDIR /src | |||||
COPY scripts scripts/ | |||||
COPY ApiGateways/*/*.csproj csproj-files/ | |||||
COPY ApiGateways/*/*/*.csproj csproj-files/ | |||||
COPY BuildingBlocks/*/*/*.csproj csproj-files/ | |||||
COPY Services/*/*/*.csproj csproj-files/ | |||||
COPY Web/*/*.csproj csproj-files/ | |||||
COPY . . | |||||
WORKDIR /src/ApiGateways/ApiGw-Base/ | |||||
RUN dotnet publish -c Release -o /app | |||||
FROM build AS publish | |||||
FROM base AS final | |||||
WORKDIR /app | |||||
COPY --from=publish /app . | |||||
ENTRYPOINT ["dotnet", "OcelotApiGw.dll"] |
@ -1,14 +0,0 @@ | |||||
FROM microsoft/dotnet:2.2-sdk | |||||
ARG BUILD_CONFIGURATION=Debug | |||||
ENV ASPNETCORE_ENVIRONMENT=Development | |||||
ENV DOTNET_USE_POLLING_FILE_WATCHER=true | |||||
EXPOSE 80 | |||||
WORKDIR /src | |||||
COPY ["src/ApiGateways/ApiGw-Base/OcelotApiGw.csproj", "src/ApiGateways/ApiGw-Base/"] | |||||
RUN dotnet restore "src/ApiGateways/ApiGw-Base/OcelotApiGw.csproj" | |||||
COPY . . | |||||
WORKDIR "/src/src/ApiGateways/ApiGw-Base" | |||||
RUN dotnet build --no-restore "OcelotApiGw.csproj" -c $BUILD_CONFIGURATION | |||||
ENTRYPOINT ["dotnet", "run", "--no-build", "--no-launch-profile", "-c", "$BUILD_CONFIGURATION", "--"] |
@ -1,18 +0,0 @@ | |||||
<Project Sdk="Microsoft.NET.Sdk.Web"> | |||||
<PropertyGroup> | |||||
<TargetFramework>netcoreapp2.2</TargetFramework> | |||||
<LangVersion>$(LangVersion)</LangVersion> | |||||
</PropertyGroup> | |||||
<ItemGroup> | |||||
<PackageReference Include="AspNetCore.HealthChecks.UI.Client" Version="2.2.2" /> | |||||
<PackageReference Include="AspNetCore.HealthChecks.Uris" Version="2.2.0" /> | |||||
<PackageReference Include="Microsoft.AspNetCore.App" Version="2.2.0" /> | |||||
<PackageReference Include="Microsoft.AspNetCore.Diagnostics.HealthChecks" Version="2.2.0" /> | |||||
<PackageReference Include="Microsoft.AspNetCore.HealthChecks" Version="1.0.0" /> | |||||
<PackageReference Include="Ocelot" Version="12.0.1" /> | |||||
<PackageReference Include="Serilog.AspNetCore" Version="2.1.1" /> | |||||
<PackageReference Include="Serilog.Sinks.Console" Version="3.1.1" /> | |||||
</ItemGroup> | |||||
</Project> |
@ -1,41 +0,0 @@ | |||||
using Microsoft.AspNetCore; | |||||
using Microsoft.AspNetCore.Hosting; | |||||
using Microsoft.Extensions.Configuration; | |||||
using Microsoft.Extensions.DependencyInjection; | |||||
using Microsoft.Extensions.Logging; | |||||
using Serilog; | |||||
using System.IO; | |||||
namespace OcelotApiGw | |||||
{ | |||||
public class Program | |||||
{ | |||||
public static void Main(string[] args) | |||||
{ | |||||
BuildWebHost(args).Run(); | |||||
} | |||||
public static IWebHost BuildWebHost(string[] args) | |||||
{ | |||||
IWebHostBuilder builder = WebHost.CreateDefaultBuilder(args); | |||||
builder.ConfigureServices(s => s.AddSingleton(builder)) | |||||
.ConfigureAppConfiguration(ic => ic.AddJsonFile(Path.Combine("configuration", "configuration.json"))) | |||||
.UseStartup<Startup>() | |||||
.ConfigureLogging((hostingContext, loggingbuilder) => | |||||
{ | |||||
loggingbuilder.AddConfiguration(hostingContext.Configuration.GetSection("Logging")); | |||||
loggingbuilder.AddConsole(); | |||||
loggingbuilder.AddDebug(); | |||||
}) | |||||
.UseSerilog((builderContext, config) => | |||||
{ | |||||
config | |||||
.MinimumLevel.Information() | |||||
.Enrich.FromLogContext() | |||||
.WriteTo.Console(); | |||||
}); | |||||
IWebHost host = builder.Build(); | |||||
return host; | |||||
} | |||||
} | |||||
} |
@ -1,27 +0,0 @@ | |||||
{ | |||||
"iisSettings": { | |||||
"windowsAuthentication": false, | |||||
"anonymousAuthentication": true, | |||||
"iisExpress": { | |||||
"applicationUrl": "http://localhost:56755/", | |||||
"sslPort": 0 | |||||
} | |||||
}, | |||||
"profiles": { | |||||
"IIS Express": { | |||||
"commandName": "IISExpress", | |||||
"launchBrowser": true, | |||||
"environmentVariables": { | |||||
"ASPNETCORE_ENVIRONMENT": "Development" | |||||
} | |||||
}, | |||||
"OcelotApiGw": { | |||||
"commandName": "Project", | |||||
"launchBrowser": true, | |||||
"environmentVariables": { | |||||
"ASPNETCORE_ENVIRONMENT": "Development" | |||||
}, | |||||
"applicationUrl": "http://localhost:64021/" | |||||
} | |||||
} | |||||
} |
@ -1,108 +0,0 @@ | |||||
using HealthChecks.UI.Client; | |||||
using Microsoft.AspNetCore.Builder; | |||||
using Microsoft.AspNetCore.Diagnostics.HealthChecks; | |||||
using Microsoft.AspNetCore.Hosting; | |||||
using Microsoft.Extensions.Configuration; | |||||
using Microsoft.Extensions.DependencyInjection; | |||||
using Microsoft.Extensions.Diagnostics.HealthChecks; | |||||
using Ocelot.DependencyInjection; | |||||
using Ocelot.Middleware; | |||||
using System; | |||||
namespace OcelotApiGw | |||||
{ | |||||
public class Startup | |||||
{ | |||||
private readonly IConfiguration _cfg; | |||||
public Startup(IConfiguration configuration) | |||||
{ | |||||
_cfg = configuration; | |||||
} | |||||
public void ConfigureServices(IServiceCollection services) | |||||
{ | |||||
var identityUrl = _cfg.GetValue<string>("IdentityUrl"); | |||||
var authenticationProviderKey = "IdentityApiKey"; | |||||
services.AddHealthChecks() | |||||
.AddCheck("self", () => HealthCheckResult.Healthy()) | |||||
.AddUrlGroup(new Uri(_cfg["CatalogUrlHC"]), name: "catalogapi-check", tags: new string[] { "catalogapi" }) | |||||
.AddUrlGroup(new Uri(_cfg["OrderingUrlHC"]), name: "orderingapi-check", tags: new string[] { "orderingapi" }) | |||||
.AddUrlGroup(new Uri(_cfg["BasketUrlHC"]), name: "basketapi-check", tags: new string[] { "basketapi" }) | |||||
.AddUrlGroup(new Uri(_cfg["IdentityUrlHC"]), name: "identityapi-check", tags: new string[] { "identityapi" }) | |||||
.AddUrlGroup(new Uri(_cfg["MarketingUrlHC"]), name: "marketingapi-check", tags: new string[] { "marketingapi" }) | |||||
.AddUrlGroup(new Uri(_cfg["PaymentUrlHC"]), name: "paymentapi-check", tags: new string[] { "paymentapi" }) | |||||
.AddUrlGroup(new Uri(_cfg["LocationUrlHC"]), name: "locationapi-check", tags: new string[] { "locationapi" }); | |||||
services.AddCors(options => | |||||
{ | |||||
options.AddPolicy("CorsPolicy", | |||||
builder => builder | |||||
.AllowAnyMethod() | |||||
.AllowAnyHeader() | |||||
.SetIsOriginAllowed((host) => true) | |||||
.AllowCredentials()); | |||||
}); | |||||
services.AddAuthentication() | |||||
.AddJwtBearer(authenticationProviderKey, x => | |||||
{ | |||||
x.Authority = identityUrl; | |||||
x.RequireHttpsMetadata = false; | |||||
x.TokenValidationParameters = new Microsoft.IdentityModel.Tokens.TokenValidationParameters() | |||||
{ | |||||
ValidAudiences = new[] { "orders", "basket", "locations", "marketing", "mobileshoppingagg", "webshoppingagg" } | |||||
}; | |||||
x.Events = new Microsoft.AspNetCore.Authentication.JwtBearer.JwtBearerEvents() | |||||
{ | |||||
OnAuthenticationFailed = async ctx => | |||||
{ | |||||
int i = 0; | |||||
}, | |||||
OnTokenValidated = async ctx => | |||||
{ | |||||
int i = 0; | |||||
}, | |||||
OnMessageReceived = async ctx => | |||||
{ | |||||
int i = 0; | |||||
} | |||||
}; | |||||
}); | |||||
services.AddOcelot(_cfg); | |||||
} | |||||
public void Configure(IApplicationBuilder app, IHostingEnvironment env) | |||||
{ | |||||
var pathBase = _cfg["PATH_BASE"]; | |||||
if (!string.IsNullOrEmpty(pathBase)) | |||||
{ | |||||
app.UsePathBase(pathBase); | |||||
} | |||||
if (env.IsDevelopment()) | |||||
{ | |||||
app.UseDeveloperExceptionPage(); | |||||
} | |||||
app.UseHealthChecks("/hc", new HealthCheckOptions() | |||||
{ | |||||
Predicate = _ => true, | |||||
ResponseWriter = UIResponseWriter.WriteHealthCheckUIResponse | |||||
}); | |||||
app.UseHealthChecks("/liveness", new HealthCheckOptions | |||||
{ | |||||
Predicate = r => r.Name.Contains("self") | |||||
}); | |||||
app.UseCors("CorsPolicy"); | |||||
app.UseOcelot().Wait(); | |||||
} | |||||
} | |||||
} |
@ -1,10 +0,0 @@ | |||||
{ | |||||
"Logging": { | |||||
"IncludeScopes": true, | |||||
"LogLevel": { | |||||
"Default": "Trace", | |||||
"System": "Information", | |||||
"Microsoft": "Information" | |||||
} | |||||
} | |||||
} |
@ -0,0 +1,49 @@ | |||||
admin: | |||||
access_log_path: "/dev/null" | |||||
address: | |||||
socket_address: | |||||
address: 0.0.0.0 | |||||
port_value: 8001 | |||||
static_resources: | |||||
listeners: | |||||
- address: | |||||
socket_address: | |||||
address: 0.0.0.0 | |||||
port_value: 80 | |||||
filter_chains: | |||||
- filters: | |||||
- name: envoy.http_connection_manager | |||||
config: | |||||
codec_type: auto | |||||
stat_prefix: ingress_http | |||||
route_config: | |||||
name: eshop_backend_route | |||||
virtual_hosts: | |||||
- name: eshop_backend | |||||
domains: | |||||
- "*" | |||||
routes: | |||||
- match: | |||||
prefix: "/api/v1/m/" | |||||
route: | |||||
prefix_rewrite: "/api/v1/" | |||||
cluster: marketing | |||||
http_filters: | |||||
- name: envoy.router | |||||
clusters: | |||||
- name: marketing | |||||
connect_timeout: 0.25s | |||||
type: logical_dns | |||||
lb_policy: round_robin | |||||
hosts: | |||||
- socket_address: | |||||
address: marketing-api | |||||
port_value: 80 | |||||
- name: locations | |||||
connect_timeout: 0.25s | |||||
type: logical_dns | |||||
lb_policy: round_robin | |||||
hosts: | |||||
- socket_address: | |||||
address: locations-api | |||||
port_value: 80 |
@ -0,0 +1,49 @@ | |||||
admin: | |||||
access_log_path: "/dev/null" | |||||
address: | |||||
socket_address: | |||||
address: 0.0.0.0 | |||||
port_value: 8001 | |||||
static_resources: | |||||
listeners: | |||||
- address: | |||||
socket_address: | |||||
address: 0.0.0.0 | |||||
port_value: 80 | |||||
filter_chains: | |||||
- filters: | |||||
- name: envoy.http_connection_manager | |||||
config: | |||||
codec_type: auto | |||||
stat_prefix: ingress_http | |||||
route_config: | |||||
name: eshop_backend_route | |||||
virtual_hosts: | |||||
- name: eshop_backend | |||||
domains: | |||||
- "*" | |||||
routes: | |||||
- match: | |||||
prefix: "/api/v1/m/" | |||||
route: | |||||
prefix_rewrite: "/api/v1/" | |||||
cluster: marketing | |||||
http_filters: | |||||
- name: envoy.router | |||||
clusters: | |||||
- name: marketing | |||||
connect_timeout: 0.25s | |||||
type: logical_dns | |||||
lb_policy: round_robin | |||||
hosts: | |||||
- socket_address: | |||||
address: marketing-api | |||||
port_value: 80 | |||||
- name: locations | |||||
connect_timeout: 0.25s | |||||
type: logical_dns | |||||
lb_policy: round_robin | |||||
hosts: | |||||
- socket_address: | |||||
address: locations-api | |||||
port_value: 80 |
@ -0,0 +1,80 @@ | |||||
admin: | |||||
access_log_path: "/dev/null" | |||||
address: | |||||
socket_address: | |||||
address: 0.0.0.0 | |||||
port_value: 8001 | |||||
static_resources: | |||||
listeners: | |||||
- address: | |||||
socket_address: | |||||
address: 0.0.0.0 | |||||
port_value: 80 | |||||
filter_chains: | |||||
- filters: | |||||
- name: envoy.http_connection_manager | |||||
config: | |||||
codec_type: auto | |||||
stat_prefix: ingress_http | |||||
route_config: | |||||
name: eshop_backend_route | |||||
virtual_hosts: | |||||
- name: eshop_backend | |||||
domains: | |||||
- "*" | |||||
routes: | |||||
- match: | |||||
prefix: "/api/v1/c/" | |||||
route: | |||||
prefix_rewrite: "/api/v1/" | |||||
cluster: catalog | |||||
- match: | |||||
prefix: "/api/v1/o/" | |||||
route: | |||||
prefix_rewrite: "/api/v1/" | |||||
cluster: ordering | |||||
- match: | |||||
prefix: "/api/v1/b/" | |||||
route: | |||||
prefix_rewrite: "/api/v1/" | |||||
cluster: basket | |||||
- match: | |||||
prefix: "/" | |||||
route: | |||||
prefix_rewrite: "/" | |||||
cluster: shoppingagg | |||||
http_filters: | |||||
- name: envoy.router | |||||
clusters: | |||||
- name: shoppingagg | |||||
connect_timeout: 0.25s | |||||
type: logical_dns | |||||
lb_policy: round_robin | |||||
hosts: | |||||
- socket_address: | |||||
address: webshoppingagg | |||||
port_value: 80 | |||||
- name: catalog | |||||
connect_timeout: 0.25s | |||||
type: logical_dns | |||||
lb_policy: round_robin | |||||
hosts: | |||||
- socket_address: | |||||
address: catalog-api | |||||
port_value: 80 | |||||
- name: basket | |||||
connect_timeout: 0.25s | |||||
type: logical_dns | |||||
lb_policy: round_robin | |||||
hosts: | |||||
- socket_address: | |||||
address: basket-api | |||||
port_value: 80 | |||||
- name: ordering | |||||
connect_timeout: 0.25s | |||||
type: logical_dns | |||||
lb_policy: round_robin | |||||
hosts: | |||||
- socket_address: | |||||
address: ordering-api | |||||
port_value: 80 |
@ -1,44 +0,0 @@ | |||||
kind: helm-release | |||||
apiVersion: 1.1 | |||||
build: | |||||
context: ..\..\..\..\ | |||||
dockerfile: ..\..\..\ApiGateways\ApiGw-Base\Dockerfile | |||||
install: | |||||
chart: ../../../../k8s/helm/apigwmm | |||||
set: | |||||
replicaCount: 1 | |||||
image: | |||||
tag: $(tag) | |||||
pullPolicy: Never | |||||
ingress: | |||||
annotations: | |||||
kubernetes.io/ingress.class: traefik-azds | |||||
hosts: | |||||
# This expands to [space.s.]webmvc.<guid>.<region>.aksapp.io | |||||
- $(spacePrefix)eshop$(hostSuffix) | |||||
inf: | |||||
k8s: | |||||
dns: $(spacePrefix)eshop$(hostSuffix) | |||||
values: | |||||
- values.dev.yaml? | |||||
- secrets.dev.yaml? | |||||
- inf.yaml | |||||
- app.yaml | |||||
configurations: | |||||
develop: | |||||
build: | |||||
useGitIgnore: true | |||||
dockerfile: ..\..\..\ApiGateways\ApiGw-Base\Dockerfile.develop | |||||
args: | |||||
BUILD_CONFIGURATION: ${BUILD_CONFIGURATION:-Debug} | |||||
container: | |||||
sync: | |||||
- '**/Pages/**' | |||||
- '**/Views/**' | |||||
- '**/wwwroot/**' | |||||
- '!**/*.{sln,csproj}' | |||||
command: [dotnet, run, --no-restore, --no-build, --no-launch-profile, -c, "${BUILD_CONFIGURATION:-Debug}"] | |||||
iterate: | |||||
processesToKill: [dotnet, vsdbg] | |||||
buildCommands: | |||||
- [dotnet, build, --no-restore, -c, "${BUILD_CONFIGURATION:-Debug}"] |
@ -1,34 +0,0 @@ | |||||
{ | |||||
"ReRoutes": [ | |||||
{ | |||||
"DownstreamPathTemplate": "/api/{version}/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "marketing.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/api/{version}/m/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/api/{version}/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "locations.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/api/{version}/l/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
} | |||||
], | |||||
"GlobalConfiguration": { | |||||
"RequestIdKey": "OcRequestId", | |||||
"AdministrationPath": "/administration" | |||||
} | |||||
} | |||||
@ -1,2 +0,0 @@ | |||||
ocelot: | |||||
configPath: /src/src/ApiGateways/ApiGw-Base/configuration |
@ -1,44 +0,0 @@ | |||||
kind: helm-release | |||||
apiVersion: 1.1 | |||||
build: | |||||
context: ..\..\..\..\ | |||||
dockerfile: ..\..\..\ApiGateways\ApiGw-Base\Dockerfile | |||||
install: | |||||
chart: ../../../../k8s/helm/apigwwm | |||||
set: | |||||
replicaCount: 1 | |||||
image: | |||||
tag: $(tag) | |||||
pullPolicy: Never | |||||
ingress: | |||||
annotations: | |||||
kubernetes.io/ingress.class: traefik-azds | |||||
hosts: | |||||
# This expands to [space.s.]webmvc.<guid>.<region>.aksapp.io | |||||
- $(spacePrefix)eshop$(hostSuffix) | |||||
inf: | |||||
k8s: | |||||
dns: $(spacePrefix)eshop$(hostSuffix) | |||||
values: | |||||
- values.dev.yaml? | |||||
- secrets.dev.yaml? | |||||
- inf.yaml | |||||
- app.yaml | |||||
configurations: | |||||
develop: | |||||
build: | |||||
useGitIgnore: true | |||||
dockerfile: ..\..\..\ApiGateways\ApiGw-Base\Dockerfile.develop | |||||
args: | |||||
BUILD_CONFIGURATION: ${BUILD_CONFIGURATION:-Debug} | |||||
container: | |||||
sync: | |||||
- '**/Pages/**' | |||||
- '**/Views/**' | |||||
- '**/wwwroot/**' | |||||
- '!**/*.{sln,csproj}' | |||||
command: [dotnet, run, --no-restore, --no-build, --no-launch-profile, -c, "${BUILD_CONFIGURATION:-Debug}"] | |||||
iterate: | |||||
processesToKill: [dotnet, vsdbg] | |||||
buildCommands: | |||||
- [dotnet, build, --no-restore, -c, "${BUILD_CONFIGURATION:-Debug}"] |
@ -1,34 +0,0 @@ | |||||
{ | |||||
"ReRoutes": [ | |||||
{ | |||||
"DownstreamPathTemplate": "/api/{version}/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "marketing.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/api/{version}/m/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/api/{version}/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "locations.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/api/{version}/l/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
} | |||||
], | |||||
"GlobalConfiguration": { | |||||
"RequestIdKey": "OcRequestId", | |||||
"AdministrationPath": "/administration" | |||||
} | |||||
} | |||||
@ -1,2 +0,0 @@ | |||||
ocelot: | |||||
configPath: /src/src/ApiGateways/ApiGw-Base/configuration |
@ -1,43 +0,0 @@ | |||||
kind: helm-release | |||||
apiVersion: 1.1 | |||||
build: | |||||
context: ..\..\..\..\ | |||||
dockerfile: ..\..\..\..\ApiGateways\ApiGw-Base\Dockerfile | |||||
install: | |||||
chart: ../../../../k8s/helm/apigwws | |||||
set: | |||||
replicaCount: 1 | |||||
image: | |||||
tag: $(tag) | |||||
pullPolicy: Never | |||||
ingress: | |||||
annotations: | |||||
kubernetes.io/ingress.class: traefik-azds | |||||
hosts: | |||||
- $(spacePrefix)eshop$(hostSuffix) | |||||
inf: | |||||
k8s: | |||||
dns: $(spacePrefix)eshop$(hostSuffix) | |||||
values: | |||||
- values.dev.yaml? | |||||
- secrets.dev.yaml? | |||||
- inf.yaml | |||||
- app.yaml | |||||
configurations: | |||||
develop: | |||||
build: | |||||
useGitIgnore: true | |||||
dockerfile: ..\..\..\ApiGateways\ApiGw-Base\Dockerfile.develop | |||||
args: | |||||
BUILD_CONFIGURATION: ${BUILD_CONFIGURATION:-Debug} | |||||
container: | |||||
sync: | |||||
- '**/Pages/**' | |||||
- '**/Views/**' | |||||
- '**/wwwroot/**' | |||||
- '!**/*.{sln,csproj}' | |||||
command: [dotnet, run, --no-restore, --no-build, --no-launch-profile, -c, "${BUILD_CONFIGURATION:-Debug}"] | |||||
iterate: | |||||
processesToKill: [dotnet, vsdbg] | |||||
buildCommands: | |||||
- [dotnet, build, --no-restore, -c, "${BUILD_CONFIGURATION:-Debug}"] |
@ -1,130 +0,0 @@ | |||||
{ | |||||
"ReRoutes": [ | |||||
{ | |||||
"DownstreamPathTemplate": "/api/{version}/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "envoy", | |||||
"Port": 51051 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/api/{version}/c/{everything}", | |||||
"UpstreamHttpMethod": [ "GET" ] | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/api/{version}/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "basket.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/api/{version}/b/{everything}", | |||||
"UpstreamHttpMethod": [], | |||||
"AuthenticationOptions": { | |||||
"AuthenticationProviderKey": "IdentityApiKey", | |||||
"AllowedScopes": [] | |||||
} | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/api/{version}/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "ordering.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/api/{version}/o/{everything}", | |||||
"UpstreamHttpMethod": [], | |||||
"AuthenticationOptions": { | |||||
"AuthenticationProviderKey": "IdentityApiKey", | |||||
"AllowedScopes": [] | |||||
} | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "webshoppingagg", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/{everything}", | |||||
"UpstreamHttpMethod": [ "POST", "PUT", "GET" ], | |||||
"AuthenticationOptions": { | |||||
"AuthenticationProviderKey": "IdentityApiKey", | |||||
"AllowedScopes": [] | |||||
} | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "ordering.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/orders-api/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "ordering.signalrhub", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/hub/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "basket.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/basket-api/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "catalog.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/catalog-api/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
}, | |||||
{ | |||||
"DownstreamPathTemplate": "/{everything}", | |||||
"DownstreamScheme": "http", | |||||
"DownstreamHostAndPorts": [ | |||||
{ | |||||
"Host": "payment.api", | |||||
"Port": 80 | |||||
} | |||||
], | |||||
"UpstreamPathTemplate": "/payment-api/{everything}", | |||||
"UpstreamHttpMethod": [] | |||||
} | |||||
], | |||||
"GlobalConfiguration": { | |||||
"RequestIdKey": "OcRequestId", | |||||
"AdministrationPath": "/administration" | |||||
} | |||||
} | |||||
@ -1,2 +0,0 @@ | |||||
ocelot: | |||||
configPath: /src/src/ApiGateways/ApiGw-Base/configuration |