uffizzi_core 2.0.9 → 2.0.11

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0e4678fb73f3c46832c31d239796e6eb99bbe66b58aef0af348d470030139312
4
- data.tar.gz: d03ff11d2723b851f01fe597ba96b6e250f68ae2d190905aa70d269bd10f0ff3
3
+ metadata.gz: 87cdaba8e373d94f9cb26dc3dcb997d3a9fe03e6073b0ed9f051f01817d42888
4
+ data.tar.gz: cd4d760782ffdda75d6f03a61cc7c96df3bc369163444cf4b33d1c16d5b084aa
5
5
  SHA512:
6
- metadata.gz: fb063735799a3a24ddc60ee808d30e67bcb90831f3e0058ee93fa0d1cea575f8949b1bc91410d781f4e38baf9cb9b9ecfed387cfe5c58bdeaecaf916a07698cb
7
- data.tar.gz: 03311442753ac1af1439287b170280e4d689d827a8dbabbffbc910045131a7ca5d35dbf5ed3dd7945fb49fd0e0d5502d5eba41f2499232887e78e04f7671fc60
6
+ metadata.gz: 17e87a12097459db02a890b6a456a6f644bdb1aadb0843b2f6527e2f2c47b77bb5e180103035a2623047253b28656f8e868af7f5fa75d61a06ccb05327d3f4bd
7
+ data.tar.gz: 26ae9224028cf8e7f8fbc40697df8481fa8579407f11d44d26ca237395feaec42bfa5668e2a8643bfc14c33992b27dbc3ca3471859eb6fee5617ee70a0e8dda6
@@ -10,10 +10,11 @@ class UffizziCore::ComposeFile::Parsers::Services::ImageParserService
10
10
 
11
11
  tag = Settings.compose.default_tag if tag.blank?
12
12
 
13
- if url?(image_path)
14
- host, namespace, name = parse_image_url(image_path)
13
+ formatted_image_path = image_path.downcase
14
+ if url?(formatted_image_path)
15
+ host, namespace, name = parse_image_url(formatted_image_path)
15
16
  else
16
- namespace, name = parse_docker_hub_image(image_path)
17
+ namespace, name = parse_docker_hub_image(formatted_image_path)
17
18
  end
18
19
 
19
20
  {
@@ -31,7 +32,8 @@ class UffizziCore::ComposeFile::Parsers::Services::ImageParserService
31
32
  end
32
33
 
33
34
  def get_image_path_and_tag(value)
34
- image_path_parts = value.downcase.split(':')
35
+ image_path_parts = value.split(':')
36
+
35
37
  case image_path_parts.size
36
38
  when 1
37
39
  image_path_parts[0]
@@ -10,7 +10,7 @@ class UffizziCore::LogsService
10
10
  logs = response.logs || []
11
11
 
12
12
  {
13
- logs: logs,
13
+ logs: format_logs(logs),
14
14
  }
15
15
  end
16
16
 
@@ -27,6 +27,14 @@ class UffizziCore::LogsService
27
27
  )
28
28
  end
29
29
 
30
+ def format_logs(logs)
31
+ logs.map do |item|
32
+ timestamp, *payload = item.split
33
+ formatted_timestamp = timestamp.present? ? timestamp.to_time(:utc).strftime('%Y-%m-%d %H:%M:%S.%L %Z') : nil
34
+ { timestamp: formatted_timestamp, payload: payload.join(' ') }
35
+ end
36
+ end
37
+
30
38
  def controller_client
31
39
  UffizziCore::ControllerClient.new
32
40
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module UffizziCore
4
- VERSION = '2.0.9'
4
+ VERSION = '2.0.11'
5
5
  end
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.0.9
4
+ version: 2.0.11
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: 2022-11-15 00:00:00.000000000 Z
12
+ date: 2022-11-23 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: aasm