Hello @ all,
I am asking myself how to bind VMs to work with just one IP form a subnet.
I have a Hetzner server configured with a routed x.x.x.x/29 subnet.
My config looks the following:
The config do work well and everything seems ok.
But now I would like to somehow bind a specific IP form my routed subnet to one VM.
Because if it is configured like that, you can use every available IP from the subnet on the VM. This is some kind of bad, because a user could change the VMs IP easy and act like another VM on the same node.
Of course I could create rules in the Firewall with "Source IP" but I don't know if this is really the correct way to do.
Maybe someone has an idea?
Thx for any hint
Regards
Andy
I am asking myself how to bind VMs to work with just one IP form a subnet.
I have a Hetzner server configured with a routed x.x.x.x/29 subnet.
My config looks the following:
Code:
# /etc/network/interfaces
### Hetzner Online GmbH - installimage
# Loopback device:
auto lo
iface lo inet loopback
# device: eth0
auto eth0
iface eth0 inet static
address <Main-IP>
netmask 255.255.255.255
pointopoint <Gateway-IP>
gateway <Gateway-IP>
# the subnet
auto vmbr1
iface vmbr1 inet static
address <my first usable IP from the subnet>
netmask <netmas of subnet>
bridge_ports none
bridge_stp off
bridge_fd 0
The config do work well and everything seems ok.
But now I would like to somehow bind a specific IP form my routed subnet to one VM.
Because if it is configured like that, you can use every available IP from the subnet on the VM. This is some kind of bad, because a user could change the VMs IP easy and act like another VM on the same node.
Of course I could create rules in the Firewall with "Source IP" but I don't know if this is really the correct way to do.
Maybe someone has an idea?
Thx for any hint
Regards
Andy