diff options
author | Christian Poessinger <christian@poessinger.com> | 2019-11-27 17:20:36 +0100 |
---|---|---|
committer | Christian Poessinger <christian@poessinger.com> | 2019-11-27 17:20:38 +0100 |
commit | 6aa3cbb611f74bdf8e44d5527f5138f3122a7497 (patch) | |
tree | 009a1fe9447bdd980d5017d49f102e7ccdace03b /docs/routing/pbr.rst | |
parent | 76bbe2744d7184ee50626d9d7b65f21dad1c7e99 (diff) | |
download | vyos-documentation-6aa3cbb611f74bdf8e44d5527f5138f3122a7497.tar.gz vyos-documentation-6aa3cbb611f74bdf8e44d5527f5138f3122a7497.zip |
Refactor "code-block:: sh" to "code-block:: console"
This will add proper new-lines into the rendered PDF. Before if it has
been a long line, not all content was preserved in the PDF.
Diffstat (limited to 'docs/routing/pbr.rst')
-rw-r--r-- | docs/routing/pbr.rst | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/docs/routing/pbr.rst b/docs/routing/pbr.rst index 9f649672..c2746fa3 100644 --- a/docs/routing/pbr.rst +++ b/docs/routing/pbr.rst @@ -13,7 +13,7 @@ Transparent Proxy The following example will show how VyOS can be used to redirect web traffic to an external transparent proxy: -.. code-block:: sh +.. code-block:: console set policy route FILTER-WEB rule 1000 destination port 80 set policy route FILTER-WEB rule 1000 protocol tcp @@ -26,7 +26,7 @@ default routing table. To create routing table 100 and add a new default gateway to be used by traffic matching our route policy: -.. code-block:: sh +.. code-block:: console set protocols static table 100 route 0.0.0.0/0 next-hop 10.255.0.2 @@ -35,7 +35,7 @@ This can be confirmed using the show ip route table 100 operational command. Finally, to apply the policy route to ingress traffic on our LAN interface, we use: -.. code-block:: sh +.. code-block:: console set interfaces ethernet eth1 policy route FILTER-WEB @@ -62,14 +62,14 @@ Routing tables that will be used in this example are: Add default routes for routing ``table 10`` and ``table 11`` -.. code-block:: sh +.. code-block:: console set protocols static table 10 route 0.0.0.0/0 next-hop 192.0.1.1 set protocols static table 11 route 0.0.0.0/0 next-hop 192.0.2.2 Add policy route matching VLAN source addresses -.. code-block:: sh +.. code-block:: console set policy route PBR rule 20 set table '10' set policy route PBR rule 20 description 'Route VLAN10 traffic to table 10' @@ -81,7 +81,7 @@ Add policy route matching VLAN source addresses Apply routing policy to **inbound** direction of out VLAN interfaces -.. code-block:: sh +.. code-block:: console set interfaces ethernet eth0 vif 10 policy route 'PBR' set interfaces ethernet eth0 vif 11 policy route 'PBR' @@ -89,7 +89,7 @@ Apply routing policy to **inbound** direction of out VLAN interfaces **OPTIONAL:** Exclude Inter-VLAN traffic (between VLAN10 and VLAN11) from PBR -.. code-block:: sh +.. code-block:: console set policy route PBR rule 10 description 'VLAN10 <-> VLAN11 shortcut' set policy route PBR rule 10 destination address '192.168.188.0/24' |