forger 1.5.0 → 1.5.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 5b3aa8428858adf323d614a2ad2d417ef111ecba07ed47f921ded9971b687e32
4
- data.tar.gz: 954cade32be1581361774f9ef33d2aac9a6b4cc37006b7a60fb28eddf2f3fde8
3
+ metadata.gz: 340a28a488dc3c34656915eb88430cee1fc377b712165788c0e6c1e6afa1b612
4
+ data.tar.gz: 5dde1b9ffbea73b11a40ee85858ef10804cf0607b150e8b436b0fe970f5a3f66
5
5
  SHA512:
6
- metadata.gz: 26d8d1882ce393975e3b0721eacaec3c36e6abfeba8b72093260872b1d56ab158c967669d8991b7d7030938f7bd2e1b9906b607d7257ba9b3e5faa110f0e561e
7
- data.tar.gz: 5cf53ac7391f7ae681b0f8951e3b7b923e11e05e29f65437ea7769db3c858b149f915a295f013a9a84f26916d1514e6633734c7a177fd962b3d052c0cb1e99ad
6
+ metadata.gz: 7817efc24a8a92c8e2556be1dd9cf19699f6163aeca5eca18a74f3d28b3e153eb679f7912890f4e4e87d58bf671ebd8eb05afe4cdcf5c7a6b653b9a9747b3e65
7
+ data.tar.gz: 84540f40d6a9acaf3f5f5e359f51c2e2c8419f398ed4ae58714049cc2f1bee04bc65b37069c0b51b7141b9512e7862977113a9ec57d3a2d05c6c58051cc8f511
@@ -3,6 +3,11 @@
3
3
  All notable changes to this project will be documented in this file.
4
4
  This project *tries* to adhere to [Semantic Versioning](http://semver.org/), even before v1.0.
5
5
 
6
+ ## [1.5.1]
7
+ - allow setting s3 endpoint to allow different s3 bucket region from instance
8
+ - remove user-data.txt log from cloudwatch
9
+ - update notes
10
+
6
11
  ## [1.5.0]
7
12
  - rename to forger
8
13
 
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- forger (1.4.9)
4
+ forger (1.5.1)
5
5
  activesupport
6
6
  aws-sdk-ec2
7
7
  aws-sdk-s3
@@ -36,7 +36,7 @@ GEM
36
36
  aws-sdk-kms (~> 1)
37
37
  aws-sigv4 (~> 1.0)
38
38
  aws-sigv4 (1.0.2)
39
- byebug (10.0.1)
39
+ byebug (10.0.2)
40
40
  codeclimate-test-reporter (1.0.8)
41
41
  simplecov (<= 0.13)
42
42
  coderay (1.1.2)
@@ -44,7 +44,7 @@ GEM
44
44
  concurrent-ruby (1.0.5)
45
45
  diff-lcs (1.3)
46
46
  docile (1.1.5)
47
- dotenv (2.2.1)
47
+ dotenv (2.2.2)
48
48
  ffi (1.9.23)
49
49
  filesize (0.1.1)
50
50
  formatador (0.2.5)
@@ -75,7 +75,7 @@ GEM
75
75
  rb-fsevent (~> 0.9, >= 0.9.4)
76
76
  rb-inotify (~> 0.9, >= 0.9.7)
77
77
  ruby_dep (~> 1.2)
78
- lumberjack (1.0.12)
78
+ lumberjack (1.0.13)
79
79
  method_source (0.9.0)
80
80
  minitest (5.11.3)
81
81
  nenv (0.3.0)
data/README.md CHANGED
@@ -146,7 +146,6 @@ You can set variables in a config file and they are available when ERB is availa
146
146
 
147
147
  ```yaml
148
148
  ---
149
- vpc_id: vpc-123
150
149
  subnets:
151
150
  - subnet-123
152
151
  - subnet-456
@@ -1,5 +1,4 @@
1
1
  ---
2
- vpc_id: vpc-111
3
2
  subnets:
4
3
  - subnet-111
5
4
  - subnet-222
@@ -69,7 +69,17 @@ class Forger::Script
69
69
  end
70
70
 
71
71
  def s3_resource
72
- @s3_resource ||= Aws::S3::Resource.new
72
+ return @s3_resource if @s3_resource
73
+
74
+ options = {}
75
+ # allow override of region for s3 client to avoid warning:
76
+ # S3 client configured for "us-east-1" but the bucket "xxx" is in "us-west-2"; Please configure the proper region to avoid multiple unnecessary redirects and signing attempts
77
+ # Example: endpoint: 'https://s3.us-west-2.amazonaws.com'
78
+ options[:endpoint] = ENV['S3_ENDPOINT'] if ENV['S3_ENDPOINT']
79
+ if options[:endpoint]
80
+ options[:region] = options[:endpoint].split('.')[1]
81
+ end
82
+ @s3_resource = Aws::S3::Resource.new(options)
73
83
  end
74
84
 
75
85
  # http://stackoverflow.com/questions/4175733/convert-duration-to-hoursminutesseconds-or-similar-in-rails-3-or-ruby
@@ -58,12 +58,6 @@ log_group_name = ${LOG_GROUP_NAME}
58
58
  log_stream_name = {instance_id}/var/log/audit/audit.log
59
59
  datetime_format =
60
60
 
61
- [/var/lib/cloud/instance/user-data.txt]
62
- file = /var/lib/cloud/instance/user-data.txt
63
- log_group_name = ${LOG_GROUP_NAME}
64
- log_stream_name = {instance_id}/var/lib/cloud/instance/user-data.txt
65
- datetime_format =
66
-
67
61
  [/var/log/messages]
68
62
  file = /var/log/messages
69
63
  log_group_name = ${LOG_GROUP_NAME}
@@ -1,3 +1,3 @@
1
1
  module Forger
2
- VERSION = "1.5.0"
2
+ VERSION = "1.5.1"
3
3
  end
@@ -1,6 +1,4 @@
1
1
  ---
2
- vpc_id: vpc-123
3
- db_subnet_group_name: default # default db subnet group associated with default vpc
4
2
  subnets:
5
3
  - subnet-123
6
4
  - subnet-456
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: forger
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0
4
+ version: 1.5.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tung Nguyen
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2018-04-18 00:00:00.000000000 Z
11
+ date: 2018-04-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -285,7 +285,7 @@ files:
285
285
  - lib/forger/script/templates/auto_terminate.sh
286
286
  - lib/forger/script/templates/auto_terminate_after_timeout.sh
287
287
  - lib/forger/script/templates/cloudwatch.sh
288
- - lib/forger/script/templates/extract_aws_ec2_scripts.sh
288
+ - lib/forger/script/templates/extract_forger_scripts.sh
289
289
  - lib/forger/script/upload.rb
290
290
  - lib/forger/scripts/auto_terminate.sh
291
291
  - lib/forger/scripts/auto_terminate/after_timeout.sh