Hmm DietPi does not use rc.local anymore for its own scripts, but we don’t touch it’s finality. But on default Raspbian/Debian images it might be not enabled.
Please check/assure that rc-local.service is enacted and rc.local executable:
systemctl enable rc-local
chmod +x /etc/rc.local
Afterwards it should work.