popito 0.0.7.alpha → 0.0.8.alpha

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: 6e2be13dac05fb75e5aaf3be210a1a193574732d8c5c5e1eca1e96c374d3b639
4
- data.tar.gz: 88b56b6c0800773f4c592a3a02de28a058ceda00ba274732b515dc226a5ecbfd
3
+ metadata.gz: a185e2e1244bfb7347732ad335ee4d6bd06059566fce5e6490cd0ff7d6c7df95
4
+ data.tar.gz: ee5bb06f7a6500086a432539ad60a7421202a43a4ed8fbedccd35a83600792f5
5
5
  SHA512:
6
- metadata.gz: 1690ec1e5a35d91cb1f60a7f7509b8476cead83873eedba99e82021e0204f90a09967e7682ea263ce432cee5bc460120d7dbf81bafb734f2bea8dd678d09f4e8
7
- data.tar.gz: c120219eb063731215970a82868fc5312134546de46ee971c23e181f57fada6ab6cef0ac16a4f2a772f5d9e7fcb9b896546fab7b25cd2455cdacfe01dbf5caea
6
+ metadata.gz: ed90aafbbaf4aa6cde3e15c5f4cbf1149eb837aef5fc8f7aa49d3002bc9d8b15065ff8a69f68ed01620132a9e5c90b2b1ad09372b6c773e4ea4b17de53b8173f
7
+ data.tar.gz: 498eaacee7f0ac93f6c990fc5bd007ffd98cab0f70ac3f178a03e00dc9f6cda94eb7fc38c5510a4810227ca5786094cdf2e4ea6c189e62b15753303e490b1d3b
data/exe/popito CHANGED
@@ -55,4 +55,5 @@ if params[:check] || params[:deploy]
55
55
  deployer = Popito::DeployExecutor.new(config_payload)
56
56
  deployer.check if params[:check]
57
57
  deployer.deploy if params[:deploy]
58
+ deployer.push_deployed_tag if params[:deploy]
58
59
  end
@@ -16,5 +16,24 @@ module Popito
16
16
  puts 'Applying generated files...'
17
17
  system "kubectl apply -f #{@deploy_files_dir}", exception: true
18
18
  end
19
+
20
+ def push_deployed_tag
21
+ yaml_build_config["build"].each do |build|
22
+ tag = build["tags"].first
23
+ puts "Pushing #{build["image"]}:#{tag} to #{build["image"]}:popito-#{config_payload.build_config[:ENVIRONMENT]}"
24
+ system "docker image tag #{build["image"]}:#{tag} #{build["image"]}:popito-#{config_payload.build_config[:ENVIRONMENT]}", exception: true
25
+ system "docker push #{build["image"]}:popito-#{config_payload.build_config['ENVIRONMENT']}", exception: true
26
+ end
27
+ end
28
+
29
+ private
30
+
31
+ def yaml_build_config
32
+ @yaml_config ||= load_build_yaml
33
+ end
34
+
35
+ def load_build_yaml
36
+ YAML.safe_load(File.read("#{config_payload.build_path}/build.yaml"))
37
+ end
19
38
  end
20
39
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Popito
4
- VERSION = "0.0.7.alpha"
4
+ VERSION = "0.0.8.alpha"
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: popito
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.7.alpha
4
+ version: 0.0.8.alpha
5
5
  platform: ruby
6
6
  authors:
7
7
  - Wagner Caixeta
8
- autorequire:
8
+ autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2022-11-22 00:00:00.000000000 Z
11
+ date: 2024-04-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: deep_merge
@@ -129,7 +129,7 @@ metadata:
129
129
  homepage_uri: http://github.com/platbr/popito
130
130
  source_code_uri: http://github.com/platbr/popito
131
131
  changelog_uri: http://github.com/platbr/popito/blob/master/CHANGELOG.md
132
- post_install_message:
132
+ post_install_message:
133
133
  rdoc_options: []
134
134
  require_paths:
135
135
  - lib
@@ -140,12 +140,12 @@ required_ruby_version: !ruby/object:Gem::Requirement
140
140
  version: 2.5.0
141
141
  required_rubygems_version: !ruby/object:Gem::Requirement
142
142
  requirements:
143
- - - ">"
143
+ - - ">="
144
144
  - !ruby/object:Gem::Version
145
- version: 1.3.1
145
+ version: '0'
146
146
  requirements: []
147
- rubygems_version: 3.0.3.1
148
- signing_key:
147
+ rubygems_version: 3.5.3
148
+ signing_key:
149
149
  specification_version: 4
150
150
  summary: 'WIP: Build docker images for Rails Projects and deploy it on K8S using a
151
151
  Popito Server.'