Class: Jekyll::Imgproxy::Tag::ImgproxyConfig

Inherits:
Object
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/jekyll/imgproxy/tag/imgproxy_config.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeImgproxyConfig

Returns a new instance of ImgproxyConfig.



21
22
23
24
25
26
# File 'lib/jekyll/imgproxy/tag/imgproxy_config.rb', line 21

def initialize
  @base_url   = fetch_config(:base_url)
  @key        = fetch_config(:key)
  @salt       = fetch_config(:salt)
  @aws_bucket = fetch_config(:aws_bucket)
end

Instance Attribute Details

#aws_bucketObject (readonly)

Returns the value of attribute aws_bucket.



15
16
17
# File 'lib/jekyll/imgproxy/tag/imgproxy_config.rb', line 15

def aws_bucket
  @aws_bucket
end

#base_urlObject (readonly)

Returns the value of attribute base_url.



15
16
17
# File 'lib/jekyll/imgproxy/tag/imgproxy_config.rb', line 15

def base_url
  @base_url
end

#keyObject (readonly)

Returns the value of attribute key.



15
16
17
# File 'lib/jekyll/imgproxy/tag/imgproxy_config.rb', line 15

def key
  @key
end

#saltObject (readonly)

Returns the value of attribute salt.



15
16
17
# File 'lib/jekyll/imgproxy/tag/imgproxy_config.rb', line 15

def salt
  @salt
end

Class Method Details

.imgproxy_configObject



11
12
13
# File 'lib/jekyll/imgproxy/tag/imgproxy_config.rb', line 11

def self.imgproxy_config
  @@imgproxy_config ||= Jekyll.configuration['imgproxy']
end