phase 1.0.0 → 1.0.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
  SHA1:
3
- metadata.gz: a5ff6bc6d3419a4db17beedd39f87f202ba5bf81
4
- data.tar.gz: f6a4b30d2ce4b88efcffba57df2ba3e55bf344d4
3
+ metadata.gz: 8b98166c521639cc9a17b9c261d187ce338115b0
4
+ data.tar.gz: 12531f8dcc6ce6107df04dbe395727b90ab95310
5
5
  SHA512:
6
- metadata.gz: 35bce38c4b5a50a287b49adaff057b08991e5f8de223f9fd4b11b44be66dff0ce728fccaab3aeafea16f6b83d682708a4ba12584fc6c05551a102aca9c444421
7
- data.tar.gz: 5f5bf3a268ede5bae6b1c6511e232adcdea5b00b8f14c2287540d4fa8a2aa3a1a347e2bdda792275b675caa3d3612365e691523063b5cf6abb4e76ac2fa9ded8
6
+ metadata.gz: 83fdd520be80187641bd67d6d2ff972d5fc12a0b71641dadc97ae26a68efa7d215f189501ed57e4996e9c7bad0a69d7dbd51b8f5973da79437a22a360ecd5864
7
+ data.tar.gz: 7f660c96a4f6dcb297b4b6e7647ab3cbd5ccab1f45c340534c099387bd3c69d4c44dffcc6e7b5d664d75e478ae9bc31a1fd150264814b5c82ee4dd5eeb3749bd
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.0.15
1
+ 1.0.1
@@ -27,7 +27,7 @@ module Phase
27
27
 
28
28
  # @return [String] any options or switches to be passed to the Docker daemon at runtime
29
29
  # @example Sample settings
30
- # config.deploy.docker_repository = "-v /dir:/dir -e VAR=value --env-file=.environment"
30
+ # config.deploy.docker_run_flags = "-v /dir:/dir -e VAR=value --env-file=.environment"
31
31
  attr_accessor :docker_run_flags
32
32
 
33
33
 
@@ -51,8 +51,8 @@ module Phase
51
51
 
52
52
  shell("docker ps > /dev/null 2>&1") do |status|
53
53
  fail <<-EOS.strip_heredoc
54
- Docker isn't responding. Is boot2docker running? Try:
55
- boot2docker start && $(boot2docker shellinit)
54
+ Docker isn't responding. Is docker-machine running? Try:
55
+ docker-machine start dev && eval $(docker-machine env dev)
56
56
  EOS
57
57
  end
58
58
 
@@ -70,12 +70,6 @@ module Phase
70
70
  ::Phase.config.deploy.docker_repository
71
71
  end
72
72
 
73
- def last_committed_mtime_for_file(file_path)
74
- rev_hash = `git rev-list HEAD "#{file_path}" | head -n 1`.chomp
75
- time_str = `git show --pretty=format:%ai --abbrev-commit #{rev_hash} | head -n 1`.chomp
76
- ::DateTime.parse(time_str).to_time
77
- end
78
-
79
73
  # FIXME: This approach isn't ideal because it compiles assets in the *working* git
80
74
  # directory rather than building in a clean, committed environment. This could lead
81
75
  # to errors in the compiled assets.
@@ -88,7 +82,6 @@ module Phase
88
82
  def prepare_clean_build
89
83
  remove_stale_build_dir!
90
84
  clone_local_git_repo
91
- # set_file_modification_timestamps
92
85
  end
93
86
 
94
87
  # This needs to run *before* the version gets updated so we know which version
@@ -113,38 +106,6 @@ module Phase
113
106
  ::FileUtils.rm_rf(build_dir)
114
107
  end
115
108
 
116
- def set_file_modification_timestamps
117
- log("Preparing docker cache...")
118
-
119
- # Threadsafe queue for multiple threads to pull from
120
- queue = ::Queue.new
121
-
122
- ::FileUtils.cd(build_dir) do
123
- # Sets consistent mtime on directories because docker cares about that too
124
- shell("find . -type d | xargs touch -t 7805200000")
125
-
126
- files = `git ls-files`.split
127
- files.each { |f| queue.push(f) }
128
-
129
- bar = ::ProgressBar.new("Setting mtimes", files.count)
130
-
131
- threads = 4.times.map do |idx|
132
- ::Thread.new do
133
- begin
134
- while path = queue.pop(true)
135
- ::FileUtils.touch(path, mtime: last_committed_mtime_for_file(path))
136
- bar.inc
137
- end
138
- rescue ThreadError
139
- end
140
- end
141
- end
142
-
143
- threads.each(&:join)
144
- bar.finish
145
- end
146
- end
147
-
148
109
  def sync_assets
149
110
  bucket = ::Phase.config.deploy.asset_bucket
150
111
  return log("Set `deploy.asset_bucket` in Phasefile to enable asset syncing") if bucket.blank?
data/lib/phase/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Phase
2
- VERSION = "1.0.0"
2
+ VERSION = "1.0.1"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: phase
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
4
+ version: 1.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Piers Mainwaring
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-06-23 00:00:00.000000000 Z
12
+ date: 2016-01-15 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: commander
@@ -261,7 +261,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
261
261
  version: '0'
262
262
  requirements: []
263
263
  rubyforge_project:
264
- rubygems_version: 2.2.3
264
+ rubygems_version: 2.4.5
265
265
  signing_key:
266
266
  specification_version: 4
267
267
  summary: A simple way to manage cloud instances within a multi-subnet network, like
@@ -269,4 +269,3 @@ summary: A simple way to manage cloud instances within a multi-subnet network, l
269
269
  test_files:
270
270
  - spec/dsl_spec.rb
271
271
  - spec/spec_helper.rb
272
- has_rdoc: