danb35 / freenas-iocage-nextcloud

Script to create an iocage jail on FreeNAS for the latest Nextcloud 28 release, including Caddy, MariaDB or PostgreSQL, and Let's Encrypt
GNU General Public License v3.0
258 stars 71 forks source link

Script fails when IP configuration is bound to secondary bridge #92

Closed kleinarne closed 4 years ago

kleinarne commented 4 years ago

I tried running the script on FreeNAS 11.2-U8.

My FreeNAS host has two NICs (igb0, igb1) connected to two managed switch ports that tag packets for different VLANs, one for internal LAN (10.0.0.0/24), one for a DMZ (10.0.1.0/24). I use tunables to create bridge1 and add igb1 to that bridge, but I don't know how to tell the script to add the jail to bridge1.

The jail then has a 10.0.1.2 IP but it's in the 10.0.0.0/24 VLAN, so it stops when testing connectivity to pkg.freebsd.org.

Is there any way to tell the script to attach the VNET to another bridge that bridge0?

PrivatePuffin commented 4 years ago

iocage create ... interfaces="vnet0:bridge99" ... Thats it :)

@kleinarne I'll make a PR for this, it's 2 minutes work. (as I already did it for my jail manager ( https://github.com/Ornias1993/jailman), So I can port the code to this script for you: )

PrivatePuffin commented 4 years ago

Done, writing a description took more time than the actual fix.