Skip to content
Snippets Groups Projects
Verified Commit 0726aafe authored by Josef Němec's avatar Josef Němec
Browse files

Create router page

parent 11e5100d
No related branches found
No related tags found
1 merge request!29Router page
Pipeline #247423 waiting for manual action
......@@ -56,62 +56,3 @@ We can create a virtual network in OpenStack for the project, which can be used
```
Additional subnet configuration is available in [official CLI documentation](https://docs.openstack.org/python-openstackclient/train/cli/command-objects/subnet.html).
## Router Creation
=== "GUI"
Navigate yourself towards **Project > Network > Routers** in the left menu and click on the **Create Router** on the right side of the window.
!!! example
![](/compute/openstack/images/networks/router1.png)
Enter router name and select external gateway with the `-GROUP` suffix.
!!! example
![](/compute/openstack/images/networks/router2.png)
Now you need to attach your internal network to the router.
**1.** Click on the router you just created.
!!! example
![](/compute/openstack/images/networks/router3.png)
**2.** Move to the **Interfaces** tab and click on the **Add interface**.
!!! example
![](/compute/openstack/images/networks/router4.png)
![](/compute/openstack/images/networks/router5.png)
**3.** Select a previously created subnet and submit.
!!! example
![](/compute/openstack/images/networks/router6.png)
=== "CLI"
**1.** **Create router**
```
openstack router create project_router
```
The current router has no ports. We need to create at least 2 interfaces: external and internal).
**2.** **Set external network for the router (select one with `-GROUP`)**
```
openstack router set --external-gateway public-muni-147-251-255-GROUP project_router
```
**3.** **Assign router as a gateway for internal network**
```
openstack router add subnet project_subnet project_router
```
Additional router configuration is available in [official CLI documentation](https://docs.openstack.org/python-openstackclient/train/cli/command-objects/router.html).
---
title: Create router
search:
exclude: false
---
# Create Router
## Router Creation
=== "GUI"
Navigate yourself towards **Project > Network > Routers** in the left menu and click on the **Create Router** on the right side of the window.
!!! example
![](/compute/openstack/images/networks/router1.png)
Enter router name and select external gateway with the `-GROUP` suffix.
!!! example
![](/compute/openstack/images/networks/router2.png)
Now you need to attach your internal network to the router.
**1.** Click on the router you just created.
!!! example
![](/compute/openstack/images/networks/router3.png)
**2.** Move to the **Interfaces** tab and click on the **Add interface**.
!!! example
![](/compute/openstack/images/networks/router4.png)
![](/compute/openstack/images/networks/router5.png)
**3.** Select a previously created subnet and submit.
!!! example
![](/compute/openstack/images/networks/router6.png)
=== "CLI"
**1.** **Create router**
```
openstack router create project_router
```
The current router has no ports. We need to create at least 2 interfaces: external and internal).
**2.** **Set external network for the router (select one with `-GROUP`)**
```
openstack router set --external-gateway public-muni-147-251-255-GROUP project_router
```
**3.** **Assign router as a gateway for internal network**
```
openstack router add subnet project_subnet project_router
```
Additional router configuration is available in [official CLI documentation](https://docs.openstack.org/python-openstackclient/train/cli/command-objects/router.html).
## Router external gateway assign
If you have no gateway on you router, you can assign a new one.
=== "GUI"
1. You can set your gateway by clicking **Set Gateway**.
!!! example
![](/compute/openstack/images/networks/set-router1.png)
2. Choose the network you desire to use (e.g. **public-cesnet-78-128-251**) and confirm.
!!! example
![](/compute/openstack/images/networks/set-router2.png)
=== "CLI"
**Set external network for the router (let us say public-muni-147-251-255-GROUP), and the external port will be created automatically**
```
openstack router set --external-gateway public-muni-147-251-255-GROUP my-router1
```
Additional router configuration is available in [official CLI documentation](https://docs.openstack.org/python-openstackclient/train/cli/command-objects/router.html).
## Router external gateway release
=== "GUI"
Navigate to the **Project > Network > Routers**. Click on the action **Clear Gateway** of your router. This action will disassociate the external network from your router, so your machines will no longer be able to access the Internet. If you get an error you need to first **Disassociate Floating IPs**.
!!! example
![](/compute/openstack/images/networks/clear-router1.png)
=== "CLI"
**Release external gateway from router**
```
openstack router unset --external-gateway my-router1
```
Make sure to first [release FIPs](../how-to-guides/allocating-floating-ips.md#release-of-floating-ip) from the network.
Additional router configuration is available in [official CLI documentation](https://docs.openstack.org/python-openstackclient/train/cli/command-objects/router.html).
topics/compute/openstack/docs/images/networks/clear-router1.png

42.1 KiB

topics/compute/openstack/docs/images/networks/set-router1.png

40.7 KiB

topics/compute/openstack/docs/images/networks/set-router2.png

66.4 KiB

......@@ -13,6 +13,7 @@ nav:
# - how-to-guides/attaching-remote-storage.md
- how-to-guides/changing-vm-resources.md
- how-to-guides/create-networking.md
- how-to-guides/create-router.md
- how-to-guides/deploying-loadbalancers.md
# - how-to-guides/high-availability-deployment.md
# - how-to-guides/maintaining-cloud-resources.md
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment