(PUP-3066) Services are started before flags are set

This patch ensures the flags are flushed out, and written into `/etc/rc.conf.local`  before the service is actually started.