Docker container inside proxmox VM cannot access the internet

kartr

New Member
Aug 9, 2024
4
0
1
I have a server from OVH that I am running Proxmox 8 on and a few VMs with Ubuntu 22 under it.

The OVH server requires custom config with Proxmox if you want to use multiple IPs as explained here (in the link below, look at the part about ADVANCE servers, it is the lesser complicated configuration from the rest and what I am using)
https://github.com/ovh/docs/blob/9d...rvers/proxmox-network-HG-Scale/guide.fr-fr.md

As explained in the guide here, the /etc/network/interfaces file on my hypervisor looks like this

Code:
auto lo
iface lo inet loopback

auto enp8s0f0np0
iface enp8s0f0np0 inet static
    address PUB_IP_DEDICATED_SERVER/32
    gateway 100.64.0.1

auto vmbr0
iface vmbr0 inet static
    address 192.168.0.1/24
    bridge-ports none
    bridge-stp off
    bridge-fd 0
    up ip route add ADDITIONAL_IP/32 dev $IFACE
    up ip route add ADDITIONAL_IP_BLOCK/28 dev $IFACE

And the netplan config on the VMs looks like this

Code:
network:
  version: 2
  ethernets:
    eth0:
      addresses:
        - 192.168.0.3/24
        - ADDITIONAL_IP/32
      routes:
        - to: default
          via: 192.168.0.1
          # Pour que les paquets à destination d'Internet aient comme source
          # l'IP publique et non l'IP privée 192.168.0.3
          from: ADDITIONAL_IP

In general, hypervisor and VMs both work normally but the problem arises with docker containers installed on the VM. They have no internet connectivity in their default bridge mode. If I run the dockers in the host mode, they have internet access but I do not want to run docker in host mode because of our setup.

Could this be related to IP routing? Expecting some help from the networking community here!
 
Hi kartr, have you found a solution? I have the exact same problem.

After various troubleshooting the docker0 interface is the problem, it cannot receive packets from outside.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!