You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We need to ensure apache starts on successive vagrant up. Currently, it seems apache is attempting to start before the shared directory mounts to /vagrant/webroot/:
[root@drupal-demonstration vagrant]# systemctl status httpd -l
● httpd.service - The Apache HTTP Server
Loaded: loaded (/usr/lib/systemd/system/httpd.service; enabled; vendor preset: disabled)
Active: failed (Result: exit-code) since Wed 2016-01-20 12:26:43 EST; 58s ago
Docs: man:httpd(8)
man:apachectl(8)
Process: 1403 ExecStop=/bin/kill -WINCH ${MAINPID} (code=exited, status=1/FAILURE)
Process: 1239 ExecStart=/usr/sbin/httpd $OPTIONS -DFOREGROUND (code=exited, status=1/FAILURE)
Main PID: 1239 (code=exited, status=1/FAILURE)
Jan 20 7:26:43 drupal-demonstration.com systemd[1]: Starting The Apache HTTP Server...
Jan 20 7:26:43 drupal-demonstration.com httpd[1239]: AH00526: Syntax error on line 119 of /etc/httpd/conf/httpd.conf:
Jan 20 7:26:43 drupal-demonstration.com httpd[1239]: DocumentRoot '/vagrant/webroot' is not a directory, or is not readable
Jan 20 7:26:43 drupal-demonstration.com systemd[1]: httpd.service: main process exited, code=exited, status=1/FAILURE
Jan 20 7:26:43 drupal-demonstration.com kill[1403]: kill: cannot find process ""
Jan 20 7:26:43 drupal-demonstration.com systemd[1]: httpd.service: control process exited, code=exited status=1
Jan 20 7:26:43 drupal-demonstration.com systemd[1]: Failed to start The Apache HTTP Server.
Jan 20 7:26:43 drupal-demonstration.com systemd[1]: Unit httpd.service entered failed state.
Jan 20 7:26:43 drupal-demonstration.com systemd[1]: httpd.service failed.
Note: apache starts on initial vagrant up build perfectly.
The text was updated successfully, but these errors were encountered:
We can attempt to implement systemctl edit, with respect to systemd.unit. Specifically, we need to add a mountpoint as a dependency (Requires, After) to httpd.service. This method is different than opening the equivalent service file, since it knows the difference between /etc/systemd, and /usr/lib/systemd, along with how to use drop-ins (.d/).
We will attempt to create another systemd service, responsible telling systemd, that the /vagrant/webroot has been mounted. We will run a loop in a shell script as Type=oneshot service. This service will execute before thehttpd service, and be similar to vagrant_mounted.pp.
We need to ensure apache starts on successive
vagrant up
. Currently, it seems apache is attempting to start before the shared directory mounts to/vagrant/webroot/
:Note: apache starts on initial
vagrant up
build perfectly.The text was updated successfully, but these errors were encountered: