How can I auto-start a site when the config file for it is created?
Ubuntu Server 13.10 Apache
How can I auto-start a site when the config file for it is created?
Ubuntu Server 13.10 Apache
The best option would be to do a graceful restart (service apache2 reload
) in order to have the config become active without downtime (the new process takes over the listener while the old process completes any active requests).
To automate this you'd need something watching the files then restarting the service.. probably not worth the effort if you're creating the site files manually.
Instead, consider using some kind of configuration management like Puppet or Chef to manage the site config files, which can then be configured to run that graceful restart every time it changes one of those files.