Hi

Stock nginx built into Synology DSM won’t cut it, so I decided to install Nginx Proxy Manager. Before doing so, I created a macvlan and assigned the NPM container to use the assigned IP. Once install is finished, and I try to launch NPM, it fails to load. I tried the same install without macvlan, and it works and loads just fine. I have installed many other containers on macvlan, so I know what I am doing and have the knowledge and experience, but I have never run into this before where there seems to be a conflict I am not aware of.

Help? Anyone?

  • @isleepbad@alien.topB
    link
    fedilink
    English
    11 year ago

    Why did you use 192.168.2.200/29 for your route? This is the last part I dont quite understand. How does it play into the settings you chose above?

    I made a typo here and it should be --ip-range 192.168.2.200/29

    As I mentioned above you are creating a virtual LAN and as such you need to carve out your own subnet.

    My setup is ip range 192.168.87.96/30 which is ip range 192.168.87.96 to 192.168.87.99 . I chose 192.168.87.99 as my auxillary and my Nginx was automatically given IP 192.168.87.96 . Now my question is how do I go about knowing what to use for route?

    What do you mean what to use for route? Given what you said your command should look like:

    docker network create -d macvlan \
    -o parent=eth0 \
    --subnet=192.168.87.0/24 \
    --gateway=192.168.87.1 \ #this is your router's address
    --ip-range 192.168.87.96/30 \
    --aux-address="host=192.168.87.99" \
    dockervlan
    

    So that command is saying: I have an entire LAN that lives on the subnet 192.168.87.0/24. My router (i.e. gateway) has the IP address 192.168.87.1. I have a virtual network (macvlan) that has its own subnet that has the range 192.168.87.96/30.

    So now you need to create the virtual subnet (macvlan) using the command

    sudo ip route add 192.168.87.96/30 dev macvlan0
    

    If you use any other subnet it wouldn’t make any sense. How else would you get the same address space you described in the ip-range option?

    • @Illuminated_Humanoid@alien.topOPB
      link
      fedilink
      English
      11 year ago

      So essentially the last step where you create a virtual subnet is going to be the same CIDR notation as the IP range. Well, I’ll be damned, it seems like I lucked out on that one and got it right.

      Thanks again. Your method worked great and for some weird reason the other methods out there such as this one and also this one did not work for me. One of the guide creators was also trying to help me, and it just wouldn’t work.

      God bless 🙏🏼