+ # Start fresh k5start daemon which will be refreshing tickets
+ # every 540 min.
+ /usr/bin/k5start -U -b -K 540 -t -p "$K5PID" -f "$KTAB"
+
+ # Run actual service with arguments as provided on command line.
+ $CMD
+
+else
+
+ # Run the command once, in the foreground, cleaning up its PID
+ # file when done.
+ /usr/bin/k5start -U -K 540 -t -p "$K5PID" -f "$KTAB" -- $CMD
+ /usr/bin/k5start -qtU -f "$KTAB" -- rm -f "$K5PID"
+fi