Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

traefik: use PathPrefixStrip and PathPrefix together

Tags:

traefik

Using trafix w/ docker backend, I would like to match all URLs of form /manage/users/api... and map them into /api.... I tried:

traefik.frontend.rule=PathPrefixStrip:/manage/users;PathPrefix:/api;

But it doesn't seem to work. Is there a way to do this?

like image 324
shaunc Avatar asked Dec 24 '22 11:12

shaunc


1 Answers

The following works:

traefik.frontend.rule=PathPrefixStrip:/manage/users/api;AddPrefix:/api;
like image 143
shaunc Avatar answered Feb 06 '23 02:02

shaunc