uffizzi_core 2.3.0 → 2.3.2
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/app/lib/uffizzi_core/concerns/models/container.rb +1 -0
- data/app/lib/uffizzi_core/concerns/models/deployment.rb +3 -1
- data/app/services/uffizzi_core/compose_file/builders/container_builder_service.rb +8 -3
- data/app/services/uffizzi_core/controller_service.rb +1 -1
- data/app/services/uffizzi_core/controller_settings_service.rb +6 -0
- data/lib/uffizzi_core/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 81b82f01fa3b61eea7546716b1d7bd696ada00810ab5ce6ca72bc6c609bb7266
|
4
|
+
data.tar.gz: da50fab31a969b5169a8025034603fb9500dc40c220a17a8fb98667f4ed14f3e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e2116c59a1f5d6f49f76bc08506e55a67bf7a8ebd4d38d5288f0d6f7664d36182206e30d33c42d88909ac7b9510122df3aa2c38cd6fd3ad6137640e213fb6a5d
|
7
|
+
data.tar.gz: 3573e168fe9af86a4d49b38b0d416cf856434c1d6a2d04ff7d1634f1947e3b25d0a34fdd72366c1f7b0e173d6a4718ed453e5f1c744b9d52a2b2e1a19c4bb360
|
@@ -9,6 +9,7 @@ module UffizziCore::Concerns::Models::Deployment
|
|
9
9
|
include UffizziCore::StateMachineConcern
|
10
10
|
include UffizziCore::DeploymentRepo
|
11
11
|
extend Enumerize
|
12
|
+
include UffizziCore::DependencyInjectionConcern
|
12
13
|
|
13
14
|
self.table_name = UffizziCore.table_names[:deployments]
|
14
15
|
|
@@ -71,7 +72,8 @@ module UffizziCore::Concerns::Models::Deployment
|
|
71
72
|
end
|
72
73
|
|
73
74
|
def preview_url
|
74
|
-
|
75
|
+
managed_dns_zone = controller_settings_service.deployment(self).managed_dns_zone
|
76
|
+
"#{subdomain}.#{managed_dns_zone}"
|
75
77
|
end
|
76
78
|
|
77
79
|
def namespace
|
@@ -29,6 +29,7 @@ class UffizziCore::ComposeFile::Builders::ContainerBuilderService
|
|
29
29
|
is_ingress = ingress_container?(container_name, ingress_data)
|
30
30
|
repo_attributes = repo_attributes(container_data, continuous_preview_global_data)
|
31
31
|
additional_subdomains = is_ingress ? ingress_data.fetch(:additional_subdomains, []) : []
|
32
|
+
memory_limit = memory_limit(deploy_data)
|
32
33
|
|
33
34
|
{
|
34
35
|
tag: tag(image_data, repo_attributes),
|
@@ -40,8 +41,8 @@ class UffizziCore::ComposeFile::Builders::ContainerBuilderService
|
|
40
41
|
command: command(container_data),
|
41
42
|
variables: variables(environment, env_file_dependencies),
|
42
43
|
secret_variables: secret_variables(secrets),
|
43
|
-
memory_limit:
|
44
|
-
memory_request:
|
44
|
+
memory_limit: memory_limit,
|
45
|
+
memory_request: memory_request(memory_limit),
|
45
46
|
repo_attributes: repo_attributes,
|
46
47
|
continuously_deploy: continuously_deploy(deploy_data),
|
47
48
|
receive_incoming_requests: is_ingress,
|
@@ -161,7 +162,7 @@ class UffizziCore::ComposeFile::Builders::ContainerBuilderService
|
|
161
162
|
command_data[:command_args].to_s
|
162
163
|
end
|
163
164
|
|
164
|
-
def
|
165
|
+
def memory_limit(deploy_data)
|
165
166
|
memory = deploy_data[:memory]
|
166
167
|
return Settings.compose.default_memory if memory.nil?
|
167
168
|
|
@@ -184,6 +185,10 @@ class UffizziCore::ComposeFile::Builders::ContainerBuilderService
|
|
184
185
|
memory_value
|
185
186
|
end
|
186
187
|
|
188
|
+
def memory_request(memory)
|
189
|
+
memory / UffizziCore::Container::REQUEST_MEMORY_RATIO
|
190
|
+
end
|
191
|
+
|
187
192
|
def continuously_deploy(deploy_data)
|
188
193
|
return :disabled if deploy_data[:auto] == false
|
189
194
|
|
@@ -145,7 +145,7 @@ class UffizziCore::ControllerService
|
|
145
145
|
def controller_client(deployable)
|
146
146
|
settings = case deployable
|
147
147
|
when UffizziCore::Deployment
|
148
|
-
|
148
|
+
controller_settings_service.deployment(deployable)
|
149
149
|
when UffizziCore::Cluster
|
150
150
|
controller_settings_service.vcluster(deployable)
|
151
151
|
else
|
data/lib/uffizzi_core/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: uffizzi_core
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.3.
|
4
|
+
version: 2.3.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Josh Thurman
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2023-
|
12
|
+
date: 2023-12-05 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: aasm
|