If you have /etc/rc.local as an executable file, it will be pulled in to the boot process by systemd-rc-local-generator / rc-local.service.
At least /etc/rc.local is the default path it uses, but this is set by the distribution. Because it's mainly for backwards compatibility, and different distributions were using different paths. E.g. on Fedora, the path is /etc/rc.d/rc.local. You can check the path as follows:
$ systemctl cat rc-local.service
# /usr/lib/systemd/system/rc-local.service
# ...
# This unit gets pulled automatically into multi-user.target by
# systemd-rc-local-generator if /etc/rc.d/rc.local is executable.
[Unit]
Description=/etc/rc.d/rc.local Compatibility
ConditionFileIsExecutable=/etc/rc.d/rc.local
After=network.target
[Service]
Type=forking
ExecStart=/etc/rc.d/rc.local start
TimeoutSec=0
RemainAfterExit=yes
GuessMainPID=no
It seems this is not very well known. There's several posts which show a previous version of the file, which has no such comment.
rc-local.servicewas never a service that was enabled viasystemctl enablebut since 2011 has been a service auto-enabled by a generator. However Arch Linux, as explained at https://unix.stackexchange.com/a/471871/5132 , does not turn on the backwards compatibility options in systemd that provide the generator in the first place. – JdeBP Nov 15 '18 at 14:33