diff options
author | Zuul <zuul@review.openstack.org> | 2018-12-20 17:03:45 +0000 |
---|---|---|
committer | Gerrit Code Review <review@openstack.org> | 2018-12-20 17:03:45 +0000 |
commit | ea844fbee81d2740c0d21ee9217da320b1b1632c (patch) | |
tree | 7096229b520479b32117ae49b44fece22ffb8ee5 /cinder/privsep | |
parent | bdc9857cfc9697318cba57b64d1a1d5944088c00 (diff) | |
parent | 923fc520744271f0431f8e39797b081263ed4f13 (diff) | |
download | cinder-ea844fbee81d2740c0d21ee9217da320b1b1632c.tar.gz |
Merge "Remove umount from volume.filters"
Diffstat (limited to 'cinder/privsep')
-rw-r--r-- | cinder/privsep/fs.py | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/cinder/privsep/fs.py b/cinder/privsep/fs.py new file mode 100644 index 000000000..e788d4e6c --- /dev/null +++ b/cinder/privsep/fs.py @@ -0,0 +1,29 @@ +# Copyright 2018 Red Hat, Inc +# Copyright 2017 Rackspace Australia +# Copyright 2018 Michael Still and Aptira +# +# Licensed under the Apache License, Version 2.0 (the "License"); you may +# not use this file except in compliance with the License. You may obtain +# a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +# License for the specific language governing permissions and limitations +# under the License. + +""" +Helpers for filesystem related routines. +""" + + +from oslo_concurrency import processutils + +import cinder.privsep + + +@cinder.privsep.sys_admin_pctxt.entrypoint +def umount(mountpoint): + processutils.execute('umount', mountpoint, attempts=1, delay_on_retry=True) |