avm-eac_rails_base0 0.11.3 → 0.11.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: 379df719867b379c8d7de7002340255222edddc1f1bf362ebcace47b1122428b
4
- data.tar.gz: d67a864973c18004d4a203b892c4682b71d95f4fa4cdd89206061592409ad3f8
3
+ metadata.gz: d7c9f7d512bcb03af8993567633bf1a0508c4ec61fb39234b039db83a7afc9a2
4
+ data.tar.gz: 51f75d248e1d6979e575b090639bab0206bfb9c4667bda7bc807f210f500c0f9
5
5
  SHA512:
6
- metadata.gz: 498351f546b54668992907f46c029b5ef37f6778023d68a5cda8b551da1b899daee540d9a2465ac7170fce942164dd1211f70b8d42f24c01f96d825f4a5a33d6
7
- data.tar.gz: 146c57be9434921badef1d28ace08802007a1b408b34c929b6fb762ef4ab314ef4a9d3017f4054d6d59d1fb47a038661dfb96f63b2d1616976d6aca378b554d9
6
+ metadata.gz: 6a1947f3d094ba1821a96f59afe7c682dd7c0ff38498627b538d2cf34fa343a0ceb324968fa16917ede0b8dc5e26b5c8462e7881ad0e8101b79ae0d98308a1df
7
+ data.tar.gz: d8b6f55f506dc10de86a89f08cc653c7b2d64ccc0c343956bac59965c626636179d7a35bc523efd5087cc8324900c97c02155419248414b92a057de70470b8c7
@@ -4,46 +4,11 @@ module Avm
4
4
  module EacRailsBase0
5
5
  module Instances
6
6
  class Deploy < ::Avm::EacRailsBase1::Instances::Deploy
7
- set_callback :assert_instance_branch, :after do
8
- bundle_install
9
- assert_database
10
- database_migrate
11
- compile_assets
12
- restart_tasks_scheduler
13
- touch_restart_file
14
- end
15
-
16
- def assert_database
17
- infom 'Asserting database...'
18
- instance.pg.assert
19
- end
20
-
21
- def bundle_install
22
- infom 'Running "bundle install"...'
23
- instance.bundle('install').system!
24
- end
25
-
26
- def compile_assets
27
- infom 'Compiling assets...'
28
- instance.rake('assets:clean', 'assets:precompile').system!
29
- end
30
-
31
- def database_migrate
32
- infom 'Running database migrations...'
33
- instance.rake('db:migrate').system!
34
- end
35
-
36
- def restart_tasks_scheduler
37
- infom 'Restarting Tasks Scheduler\'s daemon...'
38
- instance.bundle('exec', 'tasks_scheduler', 'restart').system!
39
- end
7
+ protected
40
8
 
41
- def touch_restart_file
42
- infom 'Touching restart file...'
43
- instance.host_env.command(
44
- 'touch', ::File.join(instance.read_entry(::Avm::Instances::EntryKeys::INSTALL_PATH),
45
- 'tmp', 'restart.txt')
46
- ).system!
9
+ # @return [Class<Avm::EacRailsBase0::Instances::Install>]
10
+ def install_class
11
+ ::Avm::EacRailsBase0::Instances::Install
47
12
  end
48
13
  end
49
14
  end
@@ -0,0 +1,43 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Avm
4
+ module EacRailsBase0
5
+ module Instances
6
+ class Install < ::Avm::EacRailsBase1::Instances::Install
7
+ APPENDED_JOBS = %w[bundle_install assert_database database_migrate compile_assets
8
+ touch_restart_file].freeze
9
+ JOBS = (::Avm::EacRailsBase1::Instances::Install::JOBS + APPENDED_JOBS).freeze
10
+
11
+ define_callbacks(*APPENDED_JOBS)
12
+
13
+ def assert_database
14
+ infom 'Asserting database...'
15
+ instance.pg.assert
16
+ end
17
+
18
+ def bundle_install
19
+ infom 'Running "bundle install"...'
20
+ instance.bundle('install').system!
21
+ end
22
+
23
+ def compile_assets
24
+ infom 'Compiling assets...'
25
+ instance.rake('assets:clean', 'assets:precompile').system!
26
+ end
27
+
28
+ def database_migrate
29
+ infom 'Running database migrations...'
30
+ instance.rake('db:migrate').system!
31
+ end
32
+
33
+ def touch_restart_file
34
+ infom 'Touching restart file...'
35
+ instance.host_env.command(
36
+ 'touch', ::File.join(instance.read_entry(::Avm::Instances::EntryKeys::INSTALL_PATH),
37
+ 'tmp', 'restart.txt')
38
+ ).system!
39
+ end
40
+ end
41
+ end
42
+ end
43
+ end
@@ -2,6 +2,6 @@
2
2
 
3
3
  module Avm
4
4
  module EacRailsBase0
5
- VERSION = '0.11.3'
5
+ VERSION = '0.11.4'
6
6
  end
7
7
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: avm-eac_rails_base0
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.11.3
4
+ version: 0.11.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Put here the authors
@@ -49,14 +49,14 @@ dependencies:
49
49
  requirements:
50
50
  - - "~>"
51
51
  - !ruby/object:Gem::Version
52
- version: '0.15'
52
+ version: '0.16'
53
53
  type: :development
54
54
  prerelease: false
55
55
  version_requirements: !ruby/object:Gem::Requirement
56
56
  requirements:
57
57
  - - "~>"
58
58
  - !ruby/object:Gem::Version
59
- version: '0.15'
59
+ version: '0.16'
60
60
  executables: []
61
61
  extensions: []
62
62
  extra_rdoc_files: []
@@ -66,6 +66,7 @@ files:
66
66
  - lib/avm/eac_rails_base0/instances/apache_path.rb
67
67
  - lib/avm/eac_rails_base0/instances/base.rb
68
68
  - lib/avm/eac_rails_base0/instances/deploy.rb
69
+ - lib/avm/eac_rails_base0/instances/install.rb
69
70
  - lib/avm/eac_rails_base0/source_generators/base.rb
70
71
  - lib/avm/eac_rails_base0/sources/base.rb
71
72
  - lib/avm/eac_rails_base0/sources/base/depends_on_eac_rails_base0.rb