openstax_utilities 4.4.1 → 4.4.2
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:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ffe225aee8103709252d8a81e107610a4d922413a2ce2ff5fdbfb788a59be607
|
4
|
+
data.tar.gz: 4b25a20ce6bec07a846b63fd6c5001f406542db92cdb030e12157b0e52ec4b37
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c7e1d24654420d52bf066d12570f76d2ccb41e245706c38664c048996e140af4f3d9b86fb473326c614124e6407437400e22dc12e97c2d796c8f0790fcd0ac6f
|
7
|
+
data.tar.gz: 82c5943038ded311f43b2157b5399ba8ca62757aacc36b3f3bf7f4cfc9cda4ebdbd6df2f893c82a53128f65e19a5214274b0bd432b2bb3d47b5ad0305c9abb26
|
@@ -27,17 +27,24 @@ class OpenStax::Utilities::StatusController < ActionController::Base
|
|
27
27
|
).chomp('-asg')
|
28
28
|
|
29
29
|
status = if asg.desired_capacity == 0
|
30
|
-
if
|
31
|
-
:shutting_down
|
32
|
-
elsif [ 'web', 'background', 'cron' ].include?(name)
|
30
|
+
if [ 'web', 'background', 'cron' ].include?(name)
|
33
31
|
:configuration_error
|
32
|
+
elsif asg.instances.size > 0
|
33
|
+
:shutting_down
|
34
34
|
else
|
35
35
|
:sleeping
|
36
36
|
end
|
37
37
|
elsif asg.instances.all? do |instance|
|
38
38
|
instance.health_status != 'Healthy' || instance.lifecycle_state != 'InService'
|
39
39
|
end
|
40
|
-
|
40
|
+
case name
|
41
|
+
when 'web'
|
42
|
+
:down
|
43
|
+
when 'background', 'cron'
|
44
|
+
:impacted
|
45
|
+
else
|
46
|
+
:offline
|
47
|
+
end
|
41
48
|
elsif name == 'migration'
|
42
49
|
:migrating
|
43
50
|
elsif asg.max_size > 1 && asg.desired_capacity == asg.max_size
|
@@ -1,13 +1,15 @@
|
|
1
1
|
<%
|
2
2
|
status_icons = {
|
3
|
-
|
4
|
-
|
5
|
-
|
3
|
+
configuration_error: '💀',
|
4
|
+
down: '💥',
|
5
|
+
impacted: '⚠️',
|
6
6
|
at_capacity: '🥵',
|
7
|
+
migrating: '💾',
|
7
8
|
scaling_down: '📉',
|
8
9
|
scaling_up: '📈',
|
9
|
-
migrating: '💾',
|
10
10
|
ok: '✅',
|
11
|
+
shutting_down: '😪',
|
12
|
+
offline: '🔌',
|
11
13
|
sleeping: '💤'
|
12
14
|
}
|
13
15
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: openstax_utilities
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.4.
|
4
|
+
version: 4.4.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- JP Slavinsky
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-01-
|
11
|
+
date: 2021-01-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|