broadside 1.2.0 → 1.2.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 06c6097999d33e216468be90c482378b894496aa
4
- data.tar.gz: e34ca4894bd642e4ea163f81f34f1b660b9689ba
3
+ metadata.gz: 6b7fbecd294a0d531f7b4696f4c28813ebbd9217
4
+ data.tar.gz: 3cef0f9e73cc5b926822c3ee1de1049da0e1cc18
5
5
  SHA512:
6
- metadata.gz: b583cb598536cd02b403d929ff237ea9632d124126b7f7abd03ab481f76de155a4ec489f83cfab771acc1bbf67f67fdee1112e3a1c462c6e2c1341890fae4161
7
- data.tar.gz: aebd8291a1c8b21f7ada0f827834250aa601d7e0d0f199394d6a5523ee6905cde8b8b32f70e5bef1871333f3459dd9698165544d81f6fe86a360c194ecd65bb2
6
+ metadata.gz: f321bfeb3749dc7a0d395b3366fbb7fd9604edfd01a5a49918602e27154e4fdadc5b590149ff561d4d438386b25c95470add1e035d2cab365fca4b9a1a4c8c16
7
+ data.tar.gz: 4192fdd935b51ad184e161c51ff1859ad75bfe1d956428c0e7ca0b76bf57bf0033f5aa96d50079ffa1b51aab366b9fa69ba1ad05db19a73447ebba7f22b07b72
@@ -1,3 +1,6 @@
1
+ # 1.2.1
2
+ - [#35](https://github.com/lumoslabs/broadside/pull/35/files): Allows logtail to display more than 10 lines
3
+
1
4
  # 1.2.0
2
5
  - [#32](https://github.com/lumoslabs/broadside/pull/32): Deploys will also update service configs defined in a deploy target (see full list in the [AWS Docs](https://docs.aws.amazon.com/sdkforruby/api/Aws/ECS/Client.html#create_service-instance_method))
3
6
  - Updates additional container definition configs like cpu, memory. See full list in the [AWS Docs](https://docs.aws.amazon.com/sdkforruby/api/Aws/ECS/Client.html#register_task_definition-instance_method)
@@ -110,6 +110,11 @@ command :deploy do |d|
110
110
  subcmd.arg_name 'INSTANCE'
111
111
  subcmd.flag [:n, :instance], type: Fixnum
112
112
 
113
+ subcmd.desc 'Number of lines to tail'
114
+ subcmd.default_value 10
115
+ subcmd.arg_name 'TAIL_LINES'
116
+ subcmd.flag [:l, :lines], type: Fixnum
117
+
113
118
  add_shared_deploy_configs(subcmd)
114
119
  end
115
120
 
@@ -22,6 +22,7 @@ module Broadside
22
22
  :env_vars,
23
23
  :command,
24
24
  :instance,
25
+ :lines,
25
26
  :predeploy_commands,
26
27
  :service_config,
27
28
  :task_definition_config
@@ -51,6 +52,7 @@ module Broadside
51
52
  @instance = 0
52
53
  @service_config = nil
53
54
  @task_definition_config = nil
55
+ @lines = 10
54
56
  end
55
57
 
56
58
  # Validates format of deploy targets
@@ -15,6 +15,7 @@ module Broadside
15
15
  @deploy_config.rollback = opts[:rollback] || @deploy_config.rollback
16
16
  @deploy_config.instance = opts[:instance] || @deploy_config.instance
17
17
  @deploy_config.command = opts[:command] || @deploy_config.command
18
+ @deploy_config.lines = opts[:lines] || @deploy_config.lines
18
19
  end
19
20
 
20
21
  def short
@@ -136,7 +136,7 @@ module Broadside
136
136
  ip = get_running_instance_ip
137
137
  debug "Tailing logs for running container at ip #{ip}..."
138
138
  search_pattern = Shellwords.shellescape(family)
139
- cmd = "docker logs -f --tail=10 `docker ps -n 1 --quiet --filter name=#{search_pattern}`"
139
+ cmd = "docker logs -f --tail=#{@deploy_config.lines} `docker ps -n 1 --quiet --filter name=#{search_pattern}`"
140
140
  tail_cmd = gen_ssh_cmd(ip) + " '#{cmd}'"
141
141
  exec tail_cmd
142
142
  end
@@ -1,3 +1,3 @@
1
1
  module Broadside
2
- VERSION = '1.2.0'
2
+ VERSION = '1.2.1'
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: broadside
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthew Leung
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-10-18 00:00:00.000000000 Z
11
+ date: 2016-11-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport