blob: 5f8d0000678e78aa661014fb9e309cbd771cf1e4 [file] [log] [blame]
# Copyright 2018 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 "Mount /home/chronos/user/MyFiles for ARC."
author "chromium-os-dev@chromium.org"
start on started arc-network
stop on stopping arc-network
env SOURCE=/home/chronos/user/MyFiles
env DEST=/run/arc/media/MyFiles-read
env UMASK=027
env ANDROID_ROOT_UID=0
env ANDROID_EVERYBODY_GID=9997
script
{
echo "Start arc-myfiles-read"
set -x
# Unlike other services, redirect to logger, since libfuse used in
# mount-passthrough uses stdio for logging.
exec mount-passthrough-jailed "${SOURCE}" "${DEST}" "${UMASK}" \
"${ANDROID_ROOT_UID}" "${ANDROID_EVERYBODY_GID}"
} 2>&1 | logger -t "${UPSTART_JOB}"
end script
post-stop exec logger -t "${UPSTART_JOB}" "Post-stop arc-myfiles-read"