Skip to content

Commit

Permalink
nytt forsok på å buypasse token for apne pather
Browse files Browse the repository at this point in the history
  • Loading branch information
sindredl committed Aug 9, 2024
1 parent 2f7908a commit e5781a7
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions server/src/proxy/api-proxy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,15 @@ const setup = (app: Express, audience: string) => {
}),
);

app.use(
'/tiltaksgjennomforing/api/kodeverk',
proxy(process.env.APIGW_URL, {
proxyReqPathResolver: (req) => {
return req.originalUrl.replace('/tiltaksgjennomforing/api', '/tiltaksgjennomforing-api');
},
}),
);

app.use(
'/tiltaksgjennomforing/api',
proxy(process.env.APIGW_URL as string, {
Expand Down

0 comments on commit e5781a7

Please sign in to comment.