-
Notifications
You must be signed in to change notification settings - Fork 81
hosting.config not matching with dynamic regex remap #1562
Comments
There is also another side effect with the |
We could add @dg4prez : you had similar use cases recently, I think? Any thoughts on this? |
Perhaps rather than cluttering up regex remap with more overrides for that specific use case, we remove regex remap in favor of adding more manual options to any_map. Then we could directly write the configs entries we want. I've given some rough thought to how we'd do that, though I haven't applied it to the hosting.config so we'd need to add that in there as well. Note that these would all be for advanced users who fully comprehend how traffic server works. In my opinion this is already the case for any_map and regex remap, anyway. Database changes add table anymap (deliveryservice_anymap) add table anyparent (deliveryservice_edgeparent) add table includes (deliveryservice_includes) UI Origin server base URL - remove this Remap Entries - create entries the same way we create them for regex entries - add one or a whole bunch. probably don't need order. Group of the following for each. Raw Remap Text: Note that in order to include header rewrite entries for each the header name would need to be something like xml_id_1, xml_id_2, etc. Not sure of the best answer, yet. Maybe the best way would be to place a line under each header saying what the user would need to add to the remap line in order to include it, or maybe the best way would be to have the system automatically append it. Parent entries - Same as remap entries, add as many as needed Mid Parent text: Manual includes - files we want to reference on the map lines like header rewrites etc that don't exist. We'd add each one, and the user would include the filename and contents. |
The
hosting.config
has an entry for the origin created in the Delivery service UI for a live server (volume=2 which is RAM). The problem comes when we use a REGEX to set an origin dynamically.Example Origin URL :
http://server01.kabletown.net
Then the Regex is the following :
^/(server\w\d\d)/([^?]+)(?:\.m3u8|)(.*)$ http://$1-.kabletown.net/$2
The result in the hosting.config is :
If the remap ends up with
server02.kabletown.net
then disks are used instead of RAM.The text was updated successfully, but these errors were encountered: