HEX

Warning: set_time_limit() [function.set-time-limit]: Cannot set time limit - prohibited by configuration in /home/u547966/brikov.ru/www/wp-content/plugins/admin-menu-editor/menu-editor.php on line 745
Server: Apache
System: Linux 4.19.0-0.bpo.9-amd64 x86_64 at red40
User: u547966 (5490)
PHP: 5.3.29-mh2
Disabled: syslog, dl, popen, proc_open, proc_nice, proc_get_status, proc_close, proc_terminate, posix_mkfifo, chown, chgrp, accelerator_reset, opcache_reset, accelerator_get_status, opcache_get_status, pcntl_alarm, pcntl_fork, pcntl_waitpid, pcntl_wait, pcntl_wifexited, pcntl_wifstopped, pcntl_wifsignaled, pcntl_wifcontinued, pcntl_wexitstatus, pcntl_wtermsig, pcntl_wstopsig, pcntl_signal, pcntl_signal_dispatch, pcntl_get_last_error, pcntl_strerror, pcntl_sigprocmask, pcntl_sigwaitinfo, pcntl_sigtimedwait, pcntl_exec, pcntl_getpriority, pcntl_setpriority
Upload Files
File: //var/cache/puppet/lib/puppet/type/volume_group.rb
Puppet::Type.newtype(:volume_group) do
  ensurable

  newparam(:name) do
    desc 'The name of the volume group.'
    isnamevar
  end

  newproperty(:physical_volumes, array_matching: :all) do
    desc "The list of physical volumes to be included in the volume group; this
         will automatically set these as dependencies, but they must be defined elsewhere
         using the physical_volume resource type."

    def insync?(is)
      if @resource.parameter(:followsymlinks).value == :true
        real_should = []
        real_is = []
        should.each do |s|
          if File.symlink?(s)
            device = File.expand_path(File.readlink(s), File.dirname(s))
            debug("resolved symlink '" + s + "' to device '" + device + "'")
            real_should.push device
          else
            real_should.push s
          end
        end
        is.each do |s|
          if File.symlink?(s)
            device = File.expand_path(File.readlink(s), File.dirname(s))
            debug("resolved symlink '" + s + "' to device '" + device + "'")
            real_is.push device
          else
            real_is.push s
          end
        end

        real_should.sort == real_is.sort
      else
        should.sort == is.sort
      end
    end
  end

  newparam(:followsymlinks, boolean: true) do
    desc "If set to true all current and wanted values of the physical_volumes property
      will be followed to their real files on disk if they are in fact symlinks. This is
      useful to have Puppet determine what the actual PV device is if the property value
      is a symlink, like '/dev/disk/by-path/xxxx -> ../../sda'. Defaults to `False`."
    newvalues(:true, :false)
    aliasvalue(:yes, :true)
    aliasvalue(:no, :false)
    defaultto :false
  end

  newparam(:createonly, boolean: true) do
    desc "If set to true the volume group will be created if it does not exist. If the
      volume group does exist no action will be taken. Defaults to `false`."
    newvalues(:true, :false)
    aliasvalue(:yes, :true)
    aliasvalue(:no, :false)
    defaultto :false
  end
end