Skip to content

Commit

Permalink
Merge pull request #27 from magicpages/issue/edge-server-ip-in-requests
Browse files Browse the repository at this point in the history
add trust proxy option for express
  • Loading branch information
betschki authored Aug 10, 2024
2 parents 55ada0f + a3800e6 commit 0d28ec1
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@ const BUNNYCDN_PURGE_OLD_CACHE = process.env.BUNNYCDN_PURGE_OLD_CACHE === 'true'
const BUNNYCDN_STORAGE_ZONE_NAME = process.env.BUNNYCDN_STORAGE_ZONE_NAME ?? '';
const BUNNYCDN_STORAGE_ZONE_PASSWORD = process.env.BUNNYCDN_STORAGE_ZONE_PASSWORD ?? '';

app.set('trust proxy', true);

const proxy = httpProxy.createProxyServer({
target: GHOST_URL,
secure: false,
Expand Down

0 comments on commit 0d28ec1

Please sign in to comment.