Set routes destination to env variables
B
Bergur Hallgrimsson
I suggest that the destination property under routes could be a dynamic value to better use the Preview Environment
type: rewrite
source: /api/*
destination: http://api.mydomain.com
could be
type: rewrite
source: /api/*
fromService:
name: api-service
type: web
envVarKey: ENDER_EXTERNAL_HOSTNAME
Now the rewrite works for the Preview Environment
Log In
e
engineering
Yes please, this would be huge for us. Right now we pretty much have to manually change the rewrite URL every time so that the frontend and the backend are both using the same code from our PRs.