Another workaround is just to delete the symbolic link at /etc/nginx/modules-enabled/50-mod-http-perl.conf and restart Nginx. Now, Nginx wont load the Perl module and will reload correctly.
In my case I'm using "nginx-extras" and can't purge the package libnginx-mod-http-perl due to dependencies.
Another workaround is just to delete the symbolic link at /etc/nginx/ modules- enabled/ 50-mod- http-perl. conf and restart Nginx. Now, Nginx wont load the Perl module and will reload correctly.
In my case I'm using "nginx-extras" and can't purge the package libnginx- mod-http- perl due to dependencies.