ops_team 0.20.0 → 1.0.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/lib/action.rb +3 -5
- data/lib/ops.rb +3 -3
- data/ops_team.gemspec +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: 0e74fe375694383d5cf99385e04c314e804a2ab1aae6b03558b811e78874c65e
|
4
|
+
data.tar.gz: 4c9f31d818c8bc456c4c9c37d40d42491dde28ef6e038eee77ff0e7c42e7a6da
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 87320ca1362f2691ad4808bca8b7733b2d1be4bc70b4ca06b650267bf5c50c7d69e64a554fc91d246c821e17454794ae0aadb9cca27ea747f7092f5f636a6492
|
7
|
+
data.tar.gz: 6b6bee1687f1858a1097931e336ddcf28fe4f50a9b8802cded747a034f4fefddbcab0fd4331bd961a269811384eb574bfca4e4cc69c5cca576a709bcb2cb59e0
|
data/lib/action.rb
CHANGED
@@ -17,8 +17,6 @@ class Action
|
|
17
17
|
raise NotAllowedInEnvError, "Action not allowed in #{Environment.environment} environment."
|
18
18
|
end
|
19
19
|
|
20
|
-
Secrets.load if load_secrets?
|
21
|
-
|
22
20
|
Kernel.exec(to_s)
|
23
21
|
end
|
24
22
|
|
@@ -56,12 +54,12 @@ class Action
|
|
56
54
|
end
|
57
55
|
end
|
58
56
|
|
59
|
-
private
|
60
|
-
|
61
57
|
def load_secrets?
|
62
|
-
@config["load_secrets"]
|
58
|
+
@config["load_secrets"].nil? ? false : @config["load_secrets"]
|
63
59
|
end
|
64
60
|
|
61
|
+
private
|
62
|
+
|
65
63
|
def not_in_envs
|
66
64
|
@config["not_in_envs"] || []
|
67
65
|
end
|
data/lib/ops.rb
CHANGED
@@ -108,6 +108,7 @@ class Ops
|
|
108
108
|
|
109
109
|
return builtin.run if builtin
|
110
110
|
|
111
|
+
raise UnknownActionError, "Unknown action: #{@action_name}" unless action
|
111
112
|
raise ActionConfigError, action.config_errors.join("; ") unless action.config_valid?
|
112
113
|
|
113
114
|
do_before_action
|
@@ -125,8 +126,9 @@ class Ops
|
|
125
126
|
end
|
126
127
|
|
127
128
|
def do_before_all
|
128
|
-
environment.set_variables
|
129
129
|
AppConfig.load
|
130
|
+
Secrets.load if action && action.load_secrets?
|
131
|
+
environment.set_variables
|
130
132
|
end
|
131
133
|
|
132
134
|
def do_before_action
|
@@ -159,8 +161,6 @@ class Ops
|
|
159
161
|
def action
|
160
162
|
return action_list.get(@action_name) if action_list.get(@action_name)
|
161
163
|
return action_list.get_by_alias(@action_name) if action_list.get_by_alias(@action_name)
|
162
|
-
|
163
|
-
raise UnknownActionError, "Unknown action: #{@action_name}"
|
164
164
|
end
|
165
165
|
|
166
166
|
def action_list
|
data/ops_team.gemspec
CHANGED