souls 0.7.9 → 0.8.0

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: 0f5bbeaad6e7ccce929325b5a2bf909a4a6e1d5836c00856b0fa04cd373a5b61
4
- data.tar.gz: df3ade898f6d605d1b372136701b8d72b7509e91f0be594e2ea5a8cb91e4aa0c
3
+ metadata.gz: 560643126ebd83bbba6b537f3df4ff4dab5e071a4f5eaf95c4c80b41dfad178c
4
+ data.tar.gz: 82f2814417af32ed219cd812c5f3f03239f6e612bbe357b70b98f61e31570ca3
5
5
  SHA512:
6
- metadata.gz: 4c8c11a33a54a4e37f47b0201154158b0c4849a8a28e932dd5bd084910a345ae24ad28ae26fe7ff33778e4547767faa3285e735ede3a0d23cbd3b1659a280e1f
7
- data.tar.gz: 37c09659fc9e1702438e2a79528c268b0839cec5af64323ea658ffada6129070ec306f669ccaa95923ccd6bd1cd51c9eabf7c09997ef6f403f726fa23cfd11a5
6
+ metadata.gz: ee757a67e212e058cc07b35bc8d4c74af030e9e60a7e58312623349ea5c5a6bed113ff769dcdc2eb755a7445bad7e13ba5a069636be6be18f30bfe4f34f69486
7
+ data.tar.gz: 97327b26bba04c5f4c8699540fa6a4708084c7d01a34730fb463d66a1b70ee41833c306cf4d8a9c3cc6daeff7a3d7c835ea15a7146d96f93a5dafba415369045
@@ -194,4 +194,8 @@ Style/RedundantFileExtensionInRequire:
194
194
  Style/ClassMethodsDefinitions:
195
195
  Enabled: false
196
196
  Style/GlobalStdStream:
197
+ Enabled: false
198
+ Layout/IndentationConsistency:
199
+ Enabled: false
200
+ Layout/IndentationWidth:
197
201
  Enabled: false
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- souls (0.7.5)
4
+ souls (0.7.9)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/exe/souls CHANGED
@@ -57,11 +57,12 @@ begin
57
57
  `bundle exec rspec`
58
58
  end
59
59
  when "deploy"
60
- `gcloud builds submit --config=cloudbuild.yml --project $PROJECT_ID`
60
+ project_id = Souls.configuration.project_id
61
+ `gcloud builds submit --config=cloudbuild.yml --project #{project_id}`
61
62
  else
62
63
  puts "Welcome to Souls!Yeah!"
63
64
  end
64
65
  rescue StandardError => error
65
66
  puts error
66
67
  puts "Thank you!Souls!"
67
- end
68
+ end
@@ -149,11 +149,6 @@ module Souls
149
149
  system "gcloud config set project #{project_id}"
150
150
  end
151
151
 
152
- def config_set
153
- project_id = Souls.configuration.project_id
154
- system "gcloud config set project #{project_id}"
155
- end
156
-
157
152
  def create_cluster
158
153
  app = Souls.configuration.app
159
154
  network = Souls.configuration.network
@@ -266,6 +261,9 @@ module Souls
266
261
  `gcloud services enable container.googleapis.com`
267
262
  `gcloud services enable containerregistry.googleapis.com`
268
263
  `gcloud services enable servicenetworking.googleapis.com`
264
+ `gcloud services enable sqladmin.googleapis.com`
265
+ `gcloud services enable sql-component.googleapis.com`
266
+ `gcloud services enable cloudbuild.googleapis.com`
269
267
  end
270
268
 
271
269
  def update_container zone: :asia
@@ -376,13 +374,19 @@ module Souls
376
374
  -v postgres-tmp:/var/lib/postgresql/data \
377
375
  -e POSTGRES_USER=postgres \
378
376
  -e POSTGRES_PASSWORD=postgres \
379
- -e POSTGRES_DB=souls_dev \
380
- postgres:12-alpine`
381
- system "docker ps"
377
+ -e POSTGRES_DB=souls_test \
378
+ postgres:13-alpine`
379
+ `docker ps`
380
+ end
381
+
382
+ def run_awake
383
+ app = Souls.configuration.app
384
+ `gcloud scheduler jobs create http #{app}-awake --schedule "0,10,20,30,40,50 * * * *" --uri "https://#{app}.el-soul.com" --http-method GET`
382
385
  end
383
386
 
384
387
  def deploy_local
385
388
  `docker network create --driver bridge shared`
389
+
386
390
  `docker run -d --name proxy \
387
391
  -p 80:80 -p 443:443 \
388
392
  -v "/var/run/docker.sock:/tmp/docker.sock:ro" \
@@ -392,6 +396,7 @@ module Souls
392
396
  --network shared \
393
397
  --restart always \
394
398
  jwilder/nginx-proxy`
399
+
395
400
  `docker run -d --name letsencrypt \
396
401
  -v "/home/certs:/etc/nginx/certs" \
397
402
  -v "/var/run/docker.sock:/var/run/docker.sock:ro" \
@@ -399,6 +404,7 @@ module Souls
399
404
  --network shared \
400
405
  --restart always \
401
406
  jrcs/letsencrypt-nginx-proxy-companion`
407
+
402
408
  `docker run -d --name nginx \
403
409
  -p 80:80 \
404
410
  -e VIRTUAL_HOST=souls.el-soul.com \
@@ -406,11 +412,12 @@ module Souls
406
412
  -e LETSENCRYPT_EMAIL=info@gmail.com \
407
413
  --network shared \
408
414
  --link web \
409
- poppinfumi/nginx-http:latest`
415
+ poppinfumi/ruby-nginx:latest`
416
+
410
417
  `docker run -d --name web \
411
418
  -p 3000:3000 \
412
419
  --network shared \
413
- asia.gcr.io/kaien-elixir/kaien:v2`
420
+ poppinfumi/souls_api`
414
421
  end
415
422
  end
416
423
 
@@ -12,7 +12,7 @@ module Souls
12
12
  project[:main_project_id] == "" ? project[:main_project_id] = "elsoul2" : true
13
13
  puts "Google Cloud PROJECT_ID: (default: elsoul2)"
14
14
  project[:project_id] = STDIN.gets.chomp
15
- project[:project_id] == "" ? project[:project_id] = "elsoul2" : true
15
+ project[:project_id] = "elsoul2" if project[:project_id] == ""
16
16
  puts "VPC Network Name: (default: default)"
17
17
  project[:network] = STDIN.gets.chomp
18
18
  project[:network] == "" ? project[:network] = "default" : true
@@ -1,3 +1,3 @@
1
1
  module Souls
2
- VERSION = "0.7.9"
2
+ VERSION = "0.8.0"
3
3
  end
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: 0.7.9
4
+ version: 0.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - POPPIN-FUMI
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: exe
11
11
  cert_chain: []
12
- date: 2021-01-05 00:00:00.000000000 Z
12
+ date: 2021-01-08 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description: SOULS is a Web Application Framework for Microservices on Multi Cloud
15
15
  Platform such as Google Cloud Platform, Amazon Web Services, and Alibaba Cloud.