Starting Apache httpd web server: apache2 failed!
The apache2 configtest failed. ... (warning).
Output of config test was:
mktemp: failed to create directory via template '/var/lock/apache2.XXXXXXXXXX': No such file or directory
chmod: missing operand after '755'
Try 'chmod --help' for more information.
If you are on a locked down environment, remember that /var/lock is a symlink to /run/lock as you can see here:
root@1c549706e153:~# ls -al /var/lock
lrwxrwxrwx 1 root root 9 Sep 29 00:00 /var/lock -> /run/lock
It could be that somehow you or something else deleted /run/lock so just recreate and chmod 755:
mkdir -p /run/lock
chmod 755 /run/lock
apache, mktemp, directory, via, template, var, xxxxxxxxxx, directorystarting, httpd, server, configtest, output, config, chmod, operand, symlink, ls, lrwxrwxrwx, sep, deleted, recreate, mkdir,