Also commented on Github, but I love the idea of a core and then a set of core-maintained extensions, so that unused components are not installed/running
v56.3 (Full Release Notes)
As the release of Ubuntu 22.04 creeps in, this release brings some stuff I’ve been working on for a while. Not much in quantity, but a lot of effort, love and care.
Reviewed and taken care of from top to bottom. The new control panel feels different. Different, but still familiar.
Everything feels less crammed, and there’s more space to breathe.
No more burning the eyes!
Designed from the ground up, everything has been reviewed so that it’s just as nice to use. You also get the ability to switch from light theme to dark, and vice-versa, to your heart’s content!
Of course, some plugins and software were updated, but the highlight here goes to NextCloud, as we jump from version 20.0.14 (in fact, NC 20 is actually no longer supported!) all the way to the latest version - 23.0.3!
This is (probably) the last release that will be supporting Debian 10 (buster). This is because:
- Ubuntu 22.04 ships with PHP 8.1.
- There are no releases of NextCloud supporting PHP 8.1 yet…
- But NextCloud 24 (to be released at the end of April) will support PHP 8.1
- But it will require at least PHP 7.4 - and Debian 10 comes with PHP 7.3.
As the first release supporting Ubuntu 22.04 will need to ship with NextCloud 24, it cannot support Debian 10.
If your Power Mail-in-a-Box is running Debian 10 (buster), you can perform an in-place upgrade to Debian 11 (bullseye):
- Make a backup and make sure you have access to it outside the box - just in case something goes wrong in the process;
/etc/apt/sources.listwith your favorite editor (You’ll need to use
2.1. There should be multiple lines looking like this: Where you find buster, replace with bullseye.
# /etc/apt/sources.list (old) deb https://example.com/debian buster main deb https://example.com/debian buster-updates main # /etc/apt/sources.list (new) deb https://example.com/debian bullseye main deb https://example.com/debian bullseye-updates main
- Update the packages list. It will probably tell you that there are a lot of packages needing upgrading:
sudo apt update
- Perform the upgrade, then reboot:
sudo apt upgrade --without-new-pkgs # Optional, but Debian maintainers recommend it sudo apt full-upgrade sudo reboot
- Re-run the setup:
curl -L https://power-mailinabox.net/setup.sh | sudo bash
Just trying this out. Wanted to say thanks for all the efforts!
However I tried it on a Debian 11 container and it rapidly became apparent that it’s not currently suited for it. There are things attempted that require server access:
swap space, ntpd and haveged I noticed in the system setup script.
The specific error I ran into was it couldn’t start the named systemd resolver daemon seemingly because it didn’t have permission to do an ntpd time sync
@davness If I were to spend some time trying to get it to work, do you want to support an ‘install to unprivileged container’ option? There is a chance it will be taken up by TurnKey Linux as an appliance. Then it really will be mail in a box (container)!
It is tough because Mail-in-a-Box was not exactly made with containerization in mind (and neither is the fork). The main weakness here is that the MiaB setup scripts have business to do in the kernel-space so that they can ensure the box runs properly:
- Swap allocation only happens if you have ~1.855GB of RAM or less; therefore allocating at least 2GB to the container will skip this step entirely;
- NTP is important because the box wants to ensure that the clock is synchronized properly - otherwise TLS certificates may break unexpectedly;
- haveged used to be a tool used to make sure the RNG (
/dev/urandom) on the machine is “random” enough to make cryptographic keys secure enough; this is important because some virtualized environments may not have enough entropy. However later versions of the Linux kernel already do this, and therefore it’s no longer needed - this tool will be removed starting the first version supported by Ubuntu 22.04.
Therefore - swap can solve itself if you allocate enough memory to it; haveged will be removed soon, but we still have ntp to deal with.
I’ve already started a new branch which separates these things off and asks for the platform type. Seems to work but needs more testing. I’ll submit a PR once I’m done.
v56.5 (Full Release Notes)
Ok, in the end I guess I lied about v56.3 being the last release supporting Debian 10. This is mostly a maintenance release - a couple bug fixes and some software updates:
- Fixed the
tools/owncloud-unlockadmin.shscript so that it… actually works;
- Fixed some stuff on the setup process so that Nextcloud doesn’t complain about not being able to write files - also you’ll be able to install this fork on a machine without a SSH server (who needs remote access anyway?);
- Updated Nextcloud to version 23.0.5;
That’s all for now - Ubuntu 22.04 support is relying right now on Roundcube 1.6 being released and a Z-Push version to be out (both codebases are being updated to be able to run on PHP 8.1).
That’s all for now
So I’m almost there, but I’m getting this error because of HSTS and the initial self-signed certificate.
Is there a way to kick off letsencrypt to issue the MIAB certificate as part of start.sh?
Should be fixed by clear the browser cache for the domain/IP address.
The letsencrypt certificate has not been requested yet. I think this is done automatically on the first request, but chrome won’t even go there once. Really it should be done in the setup script though. Working on it. Seems to need a
management/ssl_certificates.py run but not working either.
The setup registers the ACME account with LE but doesn’t actually request a certificate right away - honestly I’m not even sure whether this is by design or not as I haven’t actually modified that behavior.
To get around this, you can use the IP address instead: https://0.0.0.0/admin, since there isn’t an HSTS policy for IP addresses.
I think it’s by design. I think I found that the certificates are checked and issued every night by the cron job, but probably only if they have already been issued once manually through the admin interface. I guess they want the Let’s Encrypt T&Cs to be accepted before any certs are requested.
My LXC PR adds a line at the end of the setup to ensure the MIAB hostname has a Let’s Encrypt certificate.
v60.0 (Full Release Notes)
And oh boy was it a whale of an update!
Guess that at this point that everybody knows the news: Mail-in-a-Box moved to Ubuntu 22.04!
And guess who also moved to 22.04?.. rethorical question I guess
So after a bit catching up to the latest version and fighting a a bit too many merge conflicts, along with squashing a few bugs that I let stack up on the issue tracker (oops…), here are the highlights for this release:
In the dance of distribution support, because of issues that I’ve already mentioned… regarding PHP, that is, I’ve had to drop support for Debian 10 (buster).
There’s a guide on how to move to Debian 11 (bullseye) - under this fork in-place upgrades ARE supported (you do not need to make a backup, install Debian 11 from scratch, restore the backup and run the setup). Read more here: https://power-mailinabox.net/buster-eol
On the other hand, Ubuntu 22.04 (Jammy Jellyfish) is now supported! If you’re on Ubuntu 20.04 (Focal Fossa), you can either upgrade or not. That’s up to you, the fork will remain supported for the time being. Likewise, you can also upgrade in-place.
Or 24 to be exact. Since we’re still locking you to Contacts + Calendar by default, unless you like messing with that, then there’s not much to explore here. But everything’s up to date now!
Those pesky bugs! I’ve been working in squashing a few of these - some deeper than others.
That took longer than expected to get out - but it’s finally out! I’ve had a lot on my plate, hence why I could not get this out sooner.
You know who to complain to if a bug pops up. I’ll be hiding somewhere!
v60.1 (Full Release Notes)
It’s patch day!
Alright folks, I regret to announce that a stray tilde (yes! a freaking stray tilde) crashed the entire release party by basically making it impossible to receive mail. Oops…
So yeah - if you’ve upgraded to v60.0 already, PLEASE UPGRADE TO v60.1 ASAP (for your own good!)
Damn, those tildes, little buggers.
v60.4 (Full Release Notes)
Haven’t posted updates in a while, but there are some here. And a very important bugfix.
If you’re running Power Mail-in-a-Box v60.0, v60.1, v60.2 or v60.3, please upgrade ASAP - there’s a sneaky yet annoying bug that could render the box unable to pretty much receive or send mail. Read below for more info.
- If you’re running Mail-in-a-Box v60.1 (the original project), you probably should wait until they release a patch of their own. Otherwise, if you want to migrate over, I recommend testing it out in a separate box since it looks like the migration process isn’t straightforward. See this thread for more info.
If you’re already unable to do either of these things, upgrading is enough to fix the problem. No further action needed.
If you or any of your users use it’s password changing plugin to - well, change their password - you’ll eventually find out that:
- You’ll be unable to send mail.
- You’ll be unable to receive mail.
- Re-running the setup, rebooting, etc. that will not solve the problem.
You can read more here.
If you’re a fan of using the command line for admin tasks, things just got a tiny bit easier for you!
You can now use the alias
miabadm instead of having to cd into the mailinabox directory and doing
management/cli.py. Functionality remains otherwise the same.
sudo miabadmn user admins
When I try to upgrade from v60.1 to v60.4, I receive this error message
mailserver:~$ curl -L https://power-mailinabox.net/setup.sh | sudo bash
[sudo] password for adm: % Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:–:-- --:–:-- --:–:-- 0
100 3220 100 3220 0 0 4778 0 --:–:-- --:–:-- --:–:-- 13251
Updating Mail-in-a-Box to v60.4 . . .
fatal: couldn’t find remote ref refs/tags/v60.4
error: pathspec ‘v60.4’ did not match any file(s) known to git
Update failed. Did you modify something in /root/mailinabox?
Huh… assuming you did not change anything in that folder, that’s pretty weird. Try doing the following:
sudo rm -rf /root/mailinabox
(But if you did, to keep the changes, do this instead)
sudo -i # (goes into root) cd /root/mailinabox git stash
Then re-run the setup as usual:
curl -L https://power-mailinabox.net/setup.sh | sudo bash
If you ran
git stash, you can then restore the changes you did:
# In a root shell cd /root/mailinabox git stash pop
Argh… I I’m not running the maib fork, but the “original” one…
Aaaah! Suddenly makes a bit more sense
If you’re running the original Mail-in-a-Box, you either
- keep using it, or
- if you want to migrate, I’d recommend setting up a separate box and try the migration from a backup, since apparently it’s not as easy of a process as it sounds - see this thread for more info
There’s a slight confusion since the v60.1 from the original Mail-in-a-Box corresponds to v60.3 on this fork…
curl -L https://power-mailinabox.net/setup.sh | sudo bash
**** % Total % Received % Xferd Average Speed Time Time Time Current
**** Dload Upload Total Spent Left Speed**
**** 0 0 0 0 0 0 0 0 --:–:-- --:–:-- --:–:-- 0**
**100 3220 100 3220 0 0 12352 0 --:–:-- --:–:-- --:–:-- 12352
**Running migration to Mail-in-a-Box #15…
**Error: in prepare, table auto_aliases already exists (1)
**Error running the migration script:
**Command ‘[‘sqlite3’, ‘/home/user-data/mail/users.sqlite’, ‘CREATE TABLE auto_aliases (id INTEGER PRIMARY KEY AUTOINCREMENT, source TEXT NOT NULL UNIQUE, destination TEXT NOT NULL, permitted_senders TEXT);’]’ returned non-zero exit status 1.
**Your system may be in an inconsistent state now. We’re terribly sorry. A re-install from a backup might be the best way to continue.
I get this error after running “curl -L https://power-mailinabox.net/setup.sh | sudo bash”