Forum Discussion

Brad_Stapleton's avatar
Icon for Nimbostratus rankNimbostratus
Sep 02, 2021

irule to call other irules?

Is it possible to have a master irule call other irules based on URI? Our dev teams want to control their own routing and not run the risk of breaking other apps. Example: We have three applications running. When you hit /app1, the main irule will see the URI as /app1 and load the /app1 specific irule. If you hit /app2, the main irule will load the /app2 irule. This prevents someone from putting /app1 rules in the /app2 irule. Is this even possible?

1 Reply

  • Hello Brad.

    Actually, only iRule assigned to VS could be executed. So your idea of calling another iRules from a main iRule is not possible.

    Anyway, there is a way to isolate virtual hosts (app1, app2, ...) using VIP-targeting-VIP.

    The idea is to have a main VS which catches all the requests and redirects each request by app to another VS (using the "virtual" command).

    In this "new" virtual, you could assign another iRules that won't interfere with the rest of the VS.

    REF -