X7ROOT File Manager
Current Path:
/usr/lib/pcsd
usr
/
lib
/
pcsd
/
📁
..
📁
.bundle
📄
Gemfile
(223 B)
📄
Gemfile.lock
(731 B)
📄
Makefile
(1.17 KB)
📄
auth.rb
(4.78 KB)
📄
bootstrap.rb
(3.57 KB)
📄
capabilities.xml
(59.05 KB)
📄
cfgsync.rb
(23.66 KB)
📄
cluster.rb
(413 B)
📄
cluster_entity.rb
(29.81 KB)
📄
config.rb
(6.49 KB)
📄
config.ru
(440 B)
📄
corosyncconf.rb
(3.78 KB)
📄
fenceagent.rb
(1.16 KB)
📄
pcs.rb
(61.88 KB)
📄
pcsd
(695 B)
📄
pcsd-cli.rb
(4.37 KB)
📄
pcsd.8
(3.19 KB)
📄
pcsd.logrotate
(151 B)
📄
pcsd.pam
(154 B)
📄
pcsd.rb
(49.65 KB)
📄
pcsd_action_command.rb
(2.11 KB)
📄
pcsd_exchange_format.rb
(1.35 KB)
📄
pcsd_file.rb
(3.95 KB)
📄
pcsd_remove_file.rb
(595 B)
📄
permissions.rb
(4.24 KB)
📁
public
📄
remote.rb
(94.31 KB)
📄
resource.rb
(12.63 KB)
📄
rfc7919-ffdhe2048.pem
(424 B)
📄
session.rb
(2.01 KB)
📄
settings.rb
(1.15 KB)
📄
ssl.rb
(7.27 KB)
📁
vendor
📁
views
📄
wizard.rb
(418 B)
📁
wizards
Editing: pcsd_exchange_format.rb
module PcsdExchangeFormat class Error < StandardError def self.for_item(item_name, id, message) new "#{item_name} (key: #{id}): #{message}" end end end def PcsdExchangeFormat::result(code, message="") return { :code => code, :message => message, } end def PcsdExchangeFormat.no_hash_message(no_hash) return "should be 'Hash'. "+ "But it is '#{no_hash.class}': #{JSON.generate(no_hash)}" end def PcsdExchangeFormat.validate_item_map_is_Hash(items_name, item_map) unless item_map.is_a? Hash raise PcsdExchangeFormat::Error.new( "#{items_name} #{self.no_hash_message(item_map)}" ) end end def PcsdExchangeFormat.validate_item_is_Hash(item_name, id, file_data) unless file_data.is_a? Hash raise PcsdExchangeFormat::Error.for_item( item_name, id, PcsdExchangeFormat::no_hash_message(file_data) ) end end def PcsdExchangeFormat.run_action(action_types, item_name, id, action_hash) unless action_hash.has_key?(:type) raise PcsdExchangeFormat::Error.for_item(item_name, id, "'type' is missing") end unless action_types.key?(action_hash[:type]) raise PcsdExchangeFormat::Error.for_item( item_name, id, "unsupported 'type' ('#{action_hash[:type]}')"+ " supported are #{action_types.keys}" ) end return action_types[action_hash[:type]].new(id, action_hash).process() end
Upload File
Create Folder