ufo 3.1.0 → 3.1.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 +4 -4
- data/CHANGELOG.md +4 -0
- data/Gemfile.lock +1 -1
- data/lib/ufo/default.rb +2 -7
- data/lib/ufo/upgrade3.rb +18 -2
- data/lib/ufo/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d75643b59e36f0f08c8cbbf2731b6e812609e27ff417055fad1fa549aa454db9
|
4
|
+
data.tar.gz: 146706f8a36243229014cf8a4e09397506efd655284ebe199e79b7c5f3107fc8
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4706fcc082ace35482e905c587599fdc2cfbd7e6649c2f4859a51f7ba4a298c994133c8f03e817aa1285a6bb59e839ce4e6ec4ae9e99d4679a367214c34e6203
|
7
|
+
data.tar.gz: bea2d53470126f9005b6ecfe9cb366a7433a510f94cbfc4bc2dfd4f69b3eeac0e7ce6a4c3721326767893b42bd661d686460f526da07b2d087d77fb18e0308da
|
data/CHANGELOG.md
CHANGED
@@ -3,6 +3,10 @@
|
|
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
|
+
## [3.1.1]
|
7
|
+
- actually use the cluster value in settings
|
8
|
+
- upgrade variables path also #20
|
9
|
+
|
6
10
|
## [3.1.0]
|
7
11
|
- fix container_info to refer to .ufo instead of old ufo folder #20
|
8
12
|
- fix ufo upgrade3 #20
|
data/Gemfile.lock
CHANGED
data/lib/ufo/default.rb
CHANGED
@@ -9,16 +9,11 @@ module Ufo
|
|
9
9
|
# So @options must be set
|
10
10
|
module Default
|
11
11
|
# The default cluster normally defaults to the Ufo.env value.
|
12
|
-
# But it can be overriden by ufo/settings.yml
|
12
|
+
# But it can be overriden by ufo/settings.yml cluster
|
13
13
|
#
|
14
14
|
# More info: http://ufoships.com/docs/settings/
|
15
15
|
def default_cluster
|
16
|
-
|
17
|
-
if map
|
18
|
-
ecs_cluster = map[Ufo.env] || map["default"]
|
19
|
-
end
|
20
|
-
|
21
|
-
ecs_cluster || Ufo.env
|
16
|
+
setting.data["cluster"] || Ufo.env
|
22
17
|
end
|
23
18
|
|
24
19
|
# These default service values only are used when a service is created by `ufo`
|
data/lib/ufo/upgrade3.rb
CHANGED
@@ -24,8 +24,26 @@ module Ufo
|
|
24
24
|
if File.exist?(user_settings_path)
|
25
25
|
upgrade_settings(user_settings_path)
|
26
26
|
end
|
27
|
+
|
28
|
+
upgrade_variables
|
29
|
+
|
27
30
|
mv("ufo", ".ufo")
|
28
31
|
puts "Upgrade complete."
|
32
|
+
new_env_info
|
33
|
+
end
|
34
|
+
|
35
|
+
def upgrade_variables
|
36
|
+
upgrade_variable_path("dev")
|
37
|
+
upgrade_variable_path("stag")
|
38
|
+
upgrade_variable_path("prod")
|
39
|
+
end
|
40
|
+
|
41
|
+
def upgrade_variable_path(old_ufo_env)
|
42
|
+
old_path = "ufo/variables/#{old_ufo_env}.rb"
|
43
|
+
return unless File.exist?(old_path)
|
44
|
+
|
45
|
+
ufo_env = map_env(old_ufo_env)
|
46
|
+
mv(old_path, "ufo/variables/#{ufo_env}.rb")
|
29
47
|
end
|
30
48
|
|
31
49
|
def upgrade_settings(path)
|
@@ -56,8 +74,6 @@ module Ufo
|
|
56
74
|
if path.include?(ENV['HOME'])
|
57
75
|
puts "NOTE: Your ~/.ufo/settings.yml file was also upgraded to the new format. If you are using ufo in other projects those will have to be upgraded also."
|
58
76
|
end
|
59
|
-
|
60
|
-
new_env_info
|
61
77
|
end
|
62
78
|
|
63
79
|
ENV_MAP = {
|
data/lib/ufo/version.rb
CHANGED