module Fortress

Fortress is a protection mechanism for Rails applications

@author zedtux

Version manager module

@author zedtux

Constants

VERSION

Attributes

configuration[RW]

Public Class Methods

configure() { |configuration| ... } click to toggle source
# File lib/fortress/configuration.rb, line 11
def self.configure
  self.configuration ||= Configuration.new

  yield(configuration)

  apply_configuration!
end

Private Class Methods

apply_configuration!() click to toggle source
# File lib/fortress/configuration.rb, line 45
def self.apply_configuration!
  if configuration.options.try(:key?, :externals)
    fortress_allow_externals!(configuration.options[:externals])
  end
end
fortress_allow_externals!(externals) click to toggle source
# File lib/fortress/configuration.rb, line 51
def self.fortress_allow_externals!(externals)
  externals.each { |name| Mechanism.authorise!(name, :all) }
end