# # Copyright 2009-2017 Red Hat, Inc. # # This program is free software; you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by # the Free Software Foundation; either version 2 of the License, or # (at your option) any later version. # # This program is distributed in the hope that it will be useful, # but WITHOUT ANY WARRANTY; without even the implied warranty of # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the # GNU General Public License for more details. # # You should have received a copy of the GNU General Public License # along with this program; if not, write to the Free Software # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA # # Refer to the README and COPYING files for full details of the license # from __future__ import absolute_import from __future__ import division import os GLUSTER_MGMT_ENABLED = bool(@GLUSTER_MGMT@) # # file ownership definitions # VDSM_USER = '@VDSMUSER@' VDSM_GROUP = '@VDSMGROUP@' DISKIMAGE_USER = '@VDSMUSER@' DISKIMAGE_GROUP = '@QEMUGROUP@' METADATA_USER = '@METADATAUSER@' METADATA_GROUP = '@METADATAGROUP@' QEMU_PROCESS_USER = '@QEMUUSER@' QEMU_PROCESS_GROUP = '@QEMUGROUP@' OVIRT_VMCONSOLE_USER = '@OVIRTVMCONSOLEUSER@' OVIRT_VMCONSOLE_GROUP = '@OVIRTVMCONSOLEGROUP@' # Sanlock definitions SANLOCK_ENABLED = '@ENABLE_LIBVIRT_SANLOCK@' == 'yes' SANLOCK_USER = '@SNLKUSER@' # Libvirt selinux LIBVIRT_SELINUX = '@ENABLE_LIBVIRT_SELINUX@' == 'yes' MEGAB = 2 ** 20 # = 1024 ** 2 = 1 MiB GIB = 1024 * MEGAB # # Path definitions # P_LIBVIRT_VMCHANNELS = '/var/lib/libvirt/qemu/channels/' P_OVIRT_VMCONSOLES = '/var/run/ovirt-vmconsole-console/' P_VDSM = '@VDSMDIR@/' # NOQA: E501 (potentially long line) P_VDSM_HOOKS = '@HOOKSDIR@/' # NOQA: E501 (potentially long line) P_VDSM_LIB = '@VDSMLIBDIR@/' # NOQA: E501 (potentially long line) P_VDSM_RUN = '@VDSMRUNDIR@/' # NOQA: E501 (potentially long line) P_VDSM_CONF = '@CONFDIR@/' # NOQA: E501 (potentially long line) P_VDSM_LOG = '@VDSMLOGDIR@' # NOQA: E501 (potentially long line) P_VDSM_EXEC = '@LIBEXECDIR@' # NOQA: E501 (potentially long line) # # Configuration file definitions # SYSCONF_PATH = '@sysconfdir@' # # External programs (sorted, please keep in order). # EXT_CHOWN = '@CHOWN_PATH@' EXT_DD = '@DD_PATH@' EXT_DMSETUP = '@DMSETUP_PATH@' EXT_FENCE_PREFIX = os.path.dirname('@FENCE_AGENT_PATH@') + '/fence_' EXT_FSCK = '@FSCK_PATH@' EXT_FUSER = '@FUSER_PATH@' EXT_GREP = '@GREP_PATH@' EXT_IONICE = '@IONICE_PATH@' EXT_ISCSIADM = '@ISCSIADM_PATH@' EXT_KILL = '@KILL_PATH@' EXT_LVM = '@LVM_PATH@' EXT_MKFS = '@MKFS_PATH@' EXT_MKFS_MSDOS = '@MKFS_MSDOS_PATH@' EXT_MKISOFS = '@MKISOFS_PATH@' EXT_MOUNT = '@MOUNT_PATH@' EXT_MULTIPATH = '@MULTIPATH_PATH@' EXT_NICE = '@NICE_PATH@' EXT_PRLIMIT = '@PRLIMIT_PATH@' EXT_SETSID = '@SETSID_PATH@' EXT_SH = '/bin/sh' # The shell path is invariable EXT_SU = '@SU_PATH@' EXT_SUDO = '@SUDO_PATH@' EXT_TAR = '@TAR_PATH@' EXT_TASKSET = '@TASKSET_PATH@' EXT_TUNE2FS = '@TUNE2FS_PATH@' EXT_UMOUNT = '@UMOUNT_PATH@' EXT_SAFELEASE = '@SAFELEASE_PATH@' EXT_CURL_IMG_WRAP = '@LIBEXECDIR@/curl-img-wrap' # NOQA: E501 (potentially long line) EXT_FC_SCAN = '@LIBEXECDIR@/fc-scan' # NOQA: E501 (potentially long line) EXT_KVM_2_OVIRT = '@LIBEXECDIR@/kvm2ovirt' # NOQA: E501 (potentially long line)