diff --git a/README.md b/README.md index 3ce2b61..3062e9a 100644 --- a/README.md +++ b/README.md @@ -10,6 +10,6 @@ This will tag all VMs with the priority of 0 which will leave them stopp ...and so on. Informational messages are logged via the syslog facility as 'daemon.notice' entries tracking the determined order as well as the outcome for every step taken. The solution comprises two services backed by the same single method script: one activated before svc:/system/zones in order to convince it not to start any guests and the actual payload starting once vmadmd is available to evaluate the tags and complete the sequence. -SMF will import the manifests for the services upon boot-up when it initializes its repository. The location of the method script is configurable via the service property config/method_prefix, defaulting to /opt/custom/bin. The start-up delay defaults to 30 seconds, also configurable via the context environment variable DELAY for the method start. A grace period of 5 minutes is granted for shut-down, configurable via the context environment variable GRACE_PERIOD in the stop method. +SMF will import the manifests for the services upon boot-up when it initializes its repository. The location of the method script is configurable via the service property config/method_prefix, defaulting to /opt/custom/bin. The start-up delay defaults to 30 seconds, also configurable via the context environment variable DELAY for the method start. A grace period of 5 minutes is granted for shut-down, configurable via the context environment variables GRACE_PERIOD and WAIT_INTERVAL in the stop method. In the future the method script might get re-written in node.js in order to make a more human-friendly dependency notation/handling possible. This is merely the shortest path. diff --git a/guesthandler.xml b/guesthandler.xml index 2ac17f2..60906ef 100644 --- a/guesthandler.xml +++ b/guesthandler.xml @@ -18,6 +18,7 @@ + diff --git a/svc-guesthandler b/svc-guesthandler index 847d869..0fd67dd 100644 --- a/svc-guesthandler +++ b/svc-guesthandler @@ -65,7 +65,7 @@ case $1 in do if [ $(date +%s) -le $WAIT_UNTIL ]; then - sleep 1 + sleep ${WAIT_INTERVAL:-10} else exit $SMF_EXIT_ERR_FATAL fi