Closed unquietwiki closed 3 years ago
Bootstrap will always flush all packages in case there will be conflicts during install that would otherwise be fatal.
Most updates are just style/sanity and I don't mind except for comments where this does have operational effects not indented.
My biggest reason for looking at this was having tried this for the second time, and then the VM was throwing a bunch of random Python errors at me intermittently. I was able to determine that was the Google Cloud stuff being removed by the main opnsense package (I commented out the reboot command to observe this). One of the things I was told to fix said "leaving this as is may end up deleting whole directories", or something like that.
Oh and for DHCP yes it's manual for now where you could prepare a /conf/config.xml prior to bootstrap that will be picked up instead of a factory reset. We were also discussing cloud-init (available as a package too), but not sure how this can be easily leveraged.
@fichtner Good to know! BTW, if you're curious at all, or for your team's testing, https://console.cloud.google.com/marketplace/product/freebsd-cloud/freebsd-12 is was I tried this script with.
Let me cherry-pick the useful safety bits manually then and you get some rest. Thanks for the talk :)
Thanks @fichtner! Keep safe & well & I'll check back on what you come up with!
I was trying to use this with GCP's FreeBSD 12.2 image. One thing it still likes to do is strip out google-cloud-sdk, and nano if that's previously installed. In the meanwhile, I used shellcheck to audit it for potential issues & applied recommended fixes.
One other thing to look at with this: in virtualized environments like GCP, Azure, etc; the IP address for all interfaces, are already assigned, so everything needs to be DHCP. I feel like this script could help fix that ahead of time, but not sure how.
Thanks for making a good product though. Been using it for stuff for years now.