Class: FogSite
- Inherits:
-
Object
- Object
- FogSite
- Defined in:
- lib/fog_site.rb
Overview
A FogSite represents a site to be deployed to S3 and CloudFront. This object is a simple data structure, which is deployed with a ‘FogSite::Deployer`
Defined Under Namespace
Classes: Deployer
Instance Attribute Summary collapse
- #access_key_id ⇒ Object
-
#destroy_old_files ⇒ Object
Returns the value of attribute destroy_old_files.
-
#distribution_id ⇒ Object
Returns the value of attribute distribution_id.
-
#domain_name ⇒ Object
readonly
Returns the value of attribute domain_name.
- #fog_options ⇒ Object
-
#path ⇒ Object
Returns the value of attribute path.
- #secret_key ⇒ Object
Instance Method Summary collapse
- #deploy! ⇒ Object
-
#initialize(domain_name, attributes_map = {}) ⇒ FogSite
constructor
A new instance of FogSite.
Constructor Details
#initialize(domain_name, attributes_map = {}) ⇒ FogSite
Returns a new instance of FogSite.
13 14 15 16 17 18 19 |
# File 'lib/fog_site.rb', line 13 def initialize( domain_name, attributes_map = {}) @domain_name = domain_name attributes_map.each do |name, val| setter = (name.to_s + "=").to_sym self.send(setter, val) end end |
Instance Attribute Details
#access_key_id ⇒ Object
25 26 27 |
# File 'lib/fog_site.rb', line 25 def access_key_id @access_key_id || ENV["AWSAccessKeyId"] end |
#destroy_old_files ⇒ Object
Returns the value of attribute destroy_old_files.
11 12 13 |
# File 'lib/fog_site.rb', line 11 def destroy_old_files @destroy_old_files end |
#distribution_id ⇒ Object
Returns the value of attribute distribution_id.
11 12 13 |
# File 'lib/fog_site.rb', line 11 def distribution_id @distribution_id end |
#domain_name ⇒ Object (readonly)
Returns the value of attribute domain_name.
9 10 11 |
# File 'lib/fog_site.rb', line 9 def domain_name @domain_name end |
#fog_options ⇒ Object
21 22 23 |
# File 'lib/fog_site.rb', line 21 def @fog_options || {} end |
#path ⇒ Object
Returns the value of attribute path.
11 12 13 |
# File 'lib/fog_site.rb', line 11 def path @path end |
#secret_key ⇒ Object
29 30 31 |
# File 'lib/fog_site.rb', line 29 def secret_key @secret_key || ENV["AWSSecretKey"] end |