s3_website 2.5.1 → 2.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/README.md +2 -0
- data/additional-docs/example-configurations.md +22 -0
- data/bin/s3_website +7 -1
- data/changelog.md +4 -0
- data/lib/s3_website/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 092f7440dce07a7188fa3c262eb670ee1ce3fcfa
|
4
|
+
data.tar.gz: f33f91a77cebaefdfd7cb37783184a210ab06222
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fb3f83a880087f6b7f71ac89fdfe356db8c53e28c9f8b899b8bf4da8d96d1f8df4f0001af67e487d8fbee995a9c7dd4a4a5bbaac2f2b3fadee804c80b287c3df
|
7
|
+
data.tar.gz: f25b7a9f0d394497adfd2af1b672fcefc1514d739547a2bba2b83ed68b34984cf837552b457abf293f85f61f6dec46d95e3763118c7675ffdf3ab209b47c4c1f
|
data/README.md
CHANGED
@@ -44,6 +44,28 @@ environment variables. It's convenient, since you can keep the `s3_website.yml`
|
|
44
44
|
in a public Git repo, and thus have your deployment configurations
|
45
45
|
version-controlled.
|
46
46
|
|
47
|
+
Sometimes you want to use multiple CNAMEs aliases in your CloudFront distribution:
|
48
|
+
|
49
|
+
````yaml
|
50
|
+
s3_id: <%= ENV['your_domain_net_aws_key'] %>
|
51
|
+
s3_secret: <%= ENV['your_domain_net_aws_secret'] %>
|
52
|
+
s3_bucket: your.domain.net
|
53
|
+
cloudfront_distribution_id: <%= ENV['your_domain_net_cloudfront_distribution_id'] %>
|
54
|
+
cloudfront_distribution_config:
|
55
|
+
default_cache_behavior:
|
56
|
+
min_TTL: <%= 60 * 60 * 24 %>
|
57
|
+
aliases:
|
58
|
+
quantity: 3
|
59
|
+
items:
|
60
|
+
CNAME0: your1.domain.net
|
61
|
+
CNAME1: your2.domain.net
|
62
|
+
CNAME2: your3.domain.net
|
63
|
+
max_age: 120
|
64
|
+
gzip: true
|
65
|
+
````
|
66
|
+
|
67
|
+
Always remember to set the 'quantity' property to match the number of items you have.
|
68
|
+
|
47
69
|
## Using redirects
|
48
70
|
|
49
71
|
````yaml
|
data/bin/s3_website
CHANGED
@@ -33,6 +33,12 @@ class Cfg < Thor
|
|
33
33
|
:type => :boolean,
|
34
34
|
:desc => "When used with --headless, automatically create a CloudFront distribution for your S3 website."
|
35
35
|
)
|
36
|
+
option(
|
37
|
+
'config-dir',
|
38
|
+
:type => :string,
|
39
|
+
:desc => "The directory where your config file is. When not defined, s3_website will look in the current working directory.",
|
40
|
+
:default => "."
|
41
|
+
)
|
36
42
|
desc 'apply', 'Apply the configuration on the AWS services'
|
37
43
|
long_desc <<-LONGDESC
|
38
44
|
`s3_website cfg apply` will apply the configuration the S3 bucket.
|
@@ -45,7 +51,7 @@ class Cfg < Thor
|
|
45
51
|
def apply
|
46
52
|
puts 'Applying the configurations in s3_website.yml on the AWS services ...'
|
47
53
|
require 'configure-s3-website'
|
48
|
-
config_source = ConfigureS3Website::FileConfigSource.new 's3_website.yml
|
54
|
+
config_source = ConfigureS3Website::FileConfigSource.new "#{options['config-dir']}/s3_website.yml"
|
49
55
|
ConfigureS3Website::Runner.run({
|
50
56
|
:config_source => config_source,
|
51
57
|
:headless => options[:headless],
|
data/changelog.md
CHANGED
data/lib/s3_website/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: s3_website
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.6.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Lauri Lehmijoki
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-
|
11
|
+
date: 2014-11-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: thor
|