Just a strange thing I found when installing postfix on kvm vs lxc. I tested this with debian 10 and ubuntu 20.04, installed using the container templates, and bare bones installations using the ISOs on KVM.
When installing postfix, on the KVM it runs the reconfigure script, but on LXC it doesn't.
I only noticed it because I have a little script I use to install postfix on my instances and mostly I try to use LXC containers to capture the extra speed advantage, but sometimes I need KVMs. When I ran my script recently on VM it ran the reconfigure screens twice because my script had `dpkg-reconfigure postfix` in it. This caused me to investigate why, and I noticed this difference.
So two questions:
1) Why does this behavior happen? And is it limited to postfix, or could it cause a similar issue with other packages
2) Is there a way to detect LXC vs KVM so that I can modify my bash script to run `dpkg-reconfigure postfix` on LXC but skip it on KVM?
Thanks all!
When installing postfix, on the KVM it runs the reconfigure script, but on LXC it doesn't.
I only noticed it because I have a little script I use to install postfix on my instances and mostly I try to use LXC containers to capture the extra speed advantage, but sometimes I need KVMs. When I ran my script recently on VM it ran the reconfigure screens twice because my script had `dpkg-reconfigure postfix` in it. This caused me to investigate why, and I noticed this difference.
So two questions:
1) Why does this behavior happen? And is it limited to postfix, or could it cause a similar issue with other packages
2) Is there a way to detect LXC vs KVM so that I can modify my bash script to run `dpkg-reconfigure postfix` on LXC but skip it on KVM?
Thanks all!