infopark_opsworks_helpers 0.2.2 → 0.3.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
  SHA1:
3
- metadata.gz: a24732f2352838a569437fd2388fca6baa4c9952
4
- data.tar.gz: 0ebffb524adfbb5445def02c5910f5e33ed04574
3
+ metadata.gz: d3956bd41d0ebbbe9dcff978b23b066f7fbe17ae
4
+ data.tar.gz: fabfa10077289a3bcaca475989e8335ba8a8a8c0
5
5
  SHA512:
6
- metadata.gz: 67ca53b809f6d0c3c57da081173f02655853288b8bb6932c356016e815e8de53223063a55dbd7ecfb8b424ff8c2f3c902bd176fbf56f2477709dac22fbad472e
7
- data.tar.gz: afcdded05cedff41b5830e00917fac6d44b95a839d839313032b36eed80a28a243c4cb973ccb2b4a40b3d0a381bc15cf4b0197f996a7ed5f47cae5a6d9107ac6
6
+ metadata.gz: d5546728127767f9687694672bca26a1a03e0c78e5952b8ae4d8c576523a1495bc2b9772ef7b49cf27ecf6fcea9c4c3ee8db36dc3832a4849a23bfb35ae40d9b
7
+ data.tar.gz: d4d9e6bc9394fd923a84e4c37126fb67fb0388fcfec81eb5c792bbe651256ccbf5202bd08af7ba5fc10bdbdff3c29c9b4f44ac0d6b51f7d3c9a3dd94c9fbca88
@@ -1,5 +1,4 @@
1
1
  require "opsworks_helpers/engine"
2
- require "opsworks_helpers/deploy"
3
2
  require "opsworks_helpers/status_checks"
4
3
 
5
4
  module OpsworksHelpers
@@ -1,4 +1,8 @@
1
- require 'aws-sdk'
1
+ begin
2
+ require 'aws-sdk'
3
+ rescue LoadError
4
+ fail 'Please add `aws-sdk` to your Gemfile if you want to use the deployment features.'
5
+ end
2
6
 
3
7
  module OpsworksHelpers
4
8
  class Deploy
@@ -1,3 +1,3 @@
1
1
  module OpsworksHelpers
2
- VERSION = "0.2.2"
2
+ VERSION = "0.3.0"
3
3
  end
@@ -1,26 +1,33 @@
1
- namespace 'opsworks' do
2
-
3
- client = OpsworksHelpers::Deploy.new
1
+ begin
2
+ require 'opsworks_helpers/deploy'
3
+ rescue
4
+ end
4
5
 
5
- desc 'Deploy application to stack (and migrate database)'
6
- task :deploy => :environment do
7
- command_name = 'deploy'
8
- deployment_id = client.deploy({
9
- name: command_name,
10
- args: { migrate: ['true'] }
11
- })
6
+ if defined?(OpsworksHelpers::Deploy)
7
+ namespace 'opsworks' do
12
8
 
13
- client.display_deployment_result(command_name, deployment_id)
14
- end
9
+ client = OpsworksHelpers::Deploy.new
15
10
 
16
- %w(rollback restart start stop configure setup).each do |command_name|
17
- desc "Run command '#{command_name}' on OpsWorks"
18
- task command_name => :environment do
19
- deployment_id = client.deploy({name: command_name})
11
+ desc 'Deploy application to stack (and migrate database)'
12
+ task :deploy => :environment do
13
+ command_name = 'deploy'
14
+ deployment_id = client.deploy({
15
+ name: command_name,
16
+ args: { migrate: ['true'] }
17
+ })
20
18
 
21
19
  client.display_deployment_result(command_name, deployment_id)
22
20
  end
23
21
 
24
- end
22
+ %w(rollback restart start stop configure setup).each do |command_name|
23
+ desc "Run command '#{command_name}' on OpsWorks"
24
+ task command_name => :environment do
25
+ deployment_id = client.deploy({name: command_name})
25
26
 
27
+ client.display_deployment_result(command_name, deployment_id)
28
+ end
29
+
30
+ end
31
+
32
+ end
26
33
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: infopark_opsworks_helpers
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.2.2
4
+ version: 0.3.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Infopark AG
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-06-06 00:00:00.000000000 Z
12
+ date: 2016-06-22 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: bundler
@@ -81,34 +81,6 @@ dependencies:
81
81
  - - "~>"
82
82
  - !ruby/object:Gem::Version
83
83
  version: '4.2'
84
- - !ruby/object:Gem::Dependency
85
- name: haml-rails
86
- requirement: !ruby/object:Gem::Requirement
87
- requirements:
88
- - - ">="
89
- - !ruby/object:Gem::Version
90
- version: '0'
91
- type: :runtime
92
- prerelease: false
93
- version_requirements: !ruby/object:Gem::Requirement
94
- requirements:
95
- - - ">="
96
- - !ruby/object:Gem::Version
97
- version: '0'
98
- - !ruby/object:Gem::Dependency
99
- name: aws-sdk
100
- requirement: !ruby/object:Gem::Requirement
101
- requirements:
102
- - - "~>"
103
- - !ruby/object:Gem::Version
104
- version: '2'
105
- type: :runtime
106
- prerelease: false
107
- version_requirements: !ruby/object:Gem::Requirement
108
- requirements:
109
- - - "~>"
110
- - !ruby/object:Gem::Version
111
- version: '2'
112
84
  description:
113
85
  email:
114
86
  - info@infopark.de
@@ -117,12 +89,7 @@ extensions: []
117
89
  extra_rdoc_files: []
118
90
  files:
119
91
  - Rakefile
120
- - app/assets/javascripts/opsworks_helpers/application.js
121
- - app/assets/stylesheets/opsworks_helpers/application.css
122
92
  - app/controllers/opsworks_helpers/application_controller.rb
123
- - app/helpers/opsworks_helpers/application_helper.rb
124
- - app/views/application/status.html.haml
125
- - app/views/layouts/opsworks_helpers/application.html.haml
126
93
  - config/routes.rb
127
94
  - lib/opsworks_helpers.rb
128
95
  - lib/opsworks_helpers/deploy.rb
@@ -130,7 +97,7 @@ files:
130
97
  - lib/opsworks_helpers/status_checks.rb
131
98
  - lib/opsworks_helpers/version.rb
132
99
  - lib/tasks/opsworks_helpers_tasks.rake
133
- homepage: https://github.com/infopark/opsworks-helpers
100
+ homepage: https://github.com/infopark/infopark_opsworks_helpers
134
101
  licenses: []
135
102
  metadata: {}
136
103
  post_install_message:
@@ -1,13 +0,0 @@
1
- // This is a manifest file that'll be compiled into application.js, which will include all the files
2
- // listed below.
3
- //
4
- // Any JavaScript/Coffee file within this directory, lib/assets/javascripts, vendor/assets/javascripts,
5
- // or any plugin's vendor/assets/javascripts directory can be referenced here using a relative path.
6
- //
7
- // It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
8
- // compiled file.
9
- //
10
- // Read Sprockets README (https://github.com/rails/sprockets#sprockets-directives) for details
11
- // about supported directives.
12
- //
13
- //= require_tree .
@@ -1,15 +0,0 @@
1
- /*
2
- * This is a manifest file that'll be compiled into application.css, which will include all the files
3
- * listed below.
4
- *
5
- * Any CSS and SCSS file within this directory, lib/assets/stylesheets, vendor/assets/stylesheets,
6
- * or any plugin's vendor/assets/stylesheets directory can be referenced here using a relative path.
7
- *
8
- * You're free to add application-wide styles to this file and they'll appear at the bottom of the
9
- * compiled file so the styles you add here take precedence over styles defined in any styles
10
- * defined in the other CSS/SCSS files in this directory. It is generally better to create a new
11
- * file per style scope.
12
- *
13
- *= require_tree .
14
- *= require_self
15
- */
@@ -1,4 +0,0 @@
1
- module OpsworksHelpers
2
- module ApplicationHelper
3
- end
4
- end
@@ -1 +0,0 @@
1
- %h1 Status
@@ -1,11 +0,0 @@
1
- !!!
2
- %html
3
- %head
4
- %title OpsworksHelpers
5
- = stylesheet_link_tag "opsworks_helpers/application", media: "all"
6
- = javascript_include_tag "opsworks_helpers/application"
7
- = csrf_meta_tags
8
-
9
- %body
10
-
11
- = yield