| # Copyright (c) 2012 The Chromium OS Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| description "Chrome OS post-mount-encrypted cleanup" |
| author "chromium-os-dev@chromium.org" |
| |
| # This job handles delayed copying of the mount-encrypted log file into |
| # /var/log. Since mount-encrypted forks a filesystem resizing process |
| # into the background, give it a chance to at least start running before |
| # copying the log. Waiting until after system-services seems sufficient, |
| # and additionally does not add any delay to chromeos_startup itself. |
| start on started system-services |
| |
| script |
| # Copy the log (not through symlinks), and retain permissions. The |
| # target should always be removed since the log is only useful on a |
| # per-boot basis, and we don't want to follow symlinks on the target |
| # either, and use a trailing slash to require that "log" is a directory. |
| cp -aP --remove-destination /tmp/mount-encrypted.log /var/log/ || true |
| end script |