souls 1.5.0 → 1.5.4

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: 3469889eb53b99c477008678edde936ac8b0eb2d706c8e9558f952fe909d6777
4
- data.tar.gz: 1c7b81422aa93ab37bfca70caf243ec02f3946bbc7c656d6a934835400d79fed
3
+ metadata.gz: 1d1698267d5f996ab2e7163347253260c6e45b4857b9f8d9ea1adfe9e5ebf8a8
4
+ data.tar.gz: dc1dd4f776482f900f6219e74dc79d447ced21bf0110e90182b49c1e0d5543d7
5
5
  SHA512:
6
- metadata.gz: 32c16bd091866026827fec6c897622baa598197ebc89088f7ef6d0b3491532cd2d0dff775d6cd67671eae1b72fdf9e8d6dd0fbaab22270cef1c7c6ac3784d556
7
- data.tar.gz: 2afe09c0a90271def102750e8b20d4b6bc894627c48738418fb580516ef5b8bdcef165e6e42d3d3b550c2f5786f64603f1da5cd2b9308bdb9d0a0b55ef0f3834
6
+ metadata.gz: aacc81218b89d6a7987654c52d9e4a6bd3aa33ad9955a2340e3725d4bdd9a69b06db9649a8dd9754b2b4d51c068197a4fe0d647f72b9e72fcb32049a0cf55764
7
+ data.tar.gz: 100e3e13d47599bd94204e34014181036add0f41696bac35abf329cafadb96be5179438db5539c5154febeb272fd282357c4a03649ee35efafaa7e290dd0b993
@@ -23,7 +23,7 @@ module Souls
23
23
  desc "get_endpoint", "Show Worker's Endpoint"
24
24
  def get_endpoint(worker_name: "")
25
25
  project_id = Souls.configuration.project_id
26
- `gcloud run services list --project #{project_id} | grep -x #{worker_name} | awk '{print $4}'`
26
+ `gcloud run services list --project #{project_id} | grep #{worker_name} | awk '{print $4}'`
27
27
  rescue Thor::Error => e
28
28
  raise(Thor::Error, e)
29
29
  end
@@ -8,18 +8,18 @@ module Souls
8
8
  password = prompt.mask("Set DB PassWord:")
9
9
  app_name = Souls.configuration.app
10
10
  project_id = Souls.configuration.project_id
11
- instance_name = Souls.configuration.instance_name if instance_name.blank?
11
+ instance_name = Souls.configuration.instance_name
12
12
  region = Souls.configuration.region if options[:region].blank?
13
13
  db_type = options[:mysql] ? "MYSQL_8_0" : "POSTGRES_13"
14
14
 
15
15
  zone = "#{region}-b"
16
+ system("gcloud config set project #{project_id}")
16
17
  system(
17
18
  "gcloud sql instances create #{instance_name} \
18
19
  --database-version=#{db_type} --cpu=1 --memory=4096MB --zone=#{zone} \
19
20
  --root-password='#{password}' --database-flags cloudsql.iam_authentication=on"
20
21
  )
21
- instance_ip = `gcloud sql instances list | grep -x #{instance_name} | awk '{print $5}'`.strip
22
- sleep(5) until instance_ip.match?(Resolv::IPv4::Regex)
22
+ instance_ip = `gcloud sql instances list | grep #{instance_name} | awk '{print $5}'`.strip
23
23
  Dir.chdir(Souls.get_api_path.to_s) do
24
24
  file_path = ".env"
25
25
  File.open(file_path, "w") do |line|
@@ -7,6 +7,8 @@ module Souls
7
7
  puts(Paint["`souls new souls-app`", :yellow])
8
8
  exit
9
9
  end
10
+ file_dir = "./#{app_name}"
11
+ raise(StandardError, "Directory Already Exist!") if Dir.exist?(file_dir)
10
12
 
11
13
  service_name = "api"
12
14
  download_souls(app_name: app_name, service_name: service_name)
data/lib/souls/version.rb CHANGED
@@ -1,4 +1,4 @@
1
1
  module Souls
2
- VERSION = "1.5.0".freeze
2
+ VERSION = "1.5.4".freeze
3
3
  public_constant :VERSION
4
4
  end
@@ -1 +1 @@
1
- 1.5.0
1
+ 1.5.4
@@ -1 +1 @@
1
- 1.5.0
1
+ 1.5.4
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: souls
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.5.0
4
+ version: 1.5.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - POPPIN-FUMI