panter-rails-deploy 1.0.6 → 1.2.0

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
  SHA1:
3
- metadata.gz: 8bcedbf15ea4ae698b66a5d478ea3e8a2c3c2007
4
- data.tar.gz: c0f558c4d3f6c915429b6b301dc3a96ae27f1bb6
3
+ metadata.gz: 03a34036ddc89c840ae8fcee3a02d44440d0cf1d
4
+ data.tar.gz: 39e9b9fe948b5783869a79384b578a5ddc5ea147
5
5
  SHA512:
6
- metadata.gz: f0b71b7e563b088c2276d568beb6756116c4bf2cd85e2564518624fe662d375e48045d197c3f7d60f7c340bd2c0d9a76271e2ce69a64ebc82dab3adadc507284
7
- data.tar.gz: 5d7f05ce844d112939cb23792f840881ae0c3c6b48d38475006bf2f4e92a92e07713fb9e31e8a4681f2089464d3be8f72e2ec741e492cbc812d5830211d28bd4
6
+ metadata.gz: aab1a93efa2ba26a5f89b79e524c0bd53acb51b2054ef9523d1842bb07ea41d002f95a9347d7c0cea1d7df439ba18e790a8bf45d4c5d9103ecf91f38ee2600cf
7
+ data.tar.gz: 1f724779c5b0ec9167d69a72f8dd3d10e972f1ea5319725d5ad1ebedd3a7dc454a2b4ed36162eece5b0a5d79cecd3cb1c28478d7cfa60fba92c8d5beb3cc4da1
data/LICENSE CHANGED
@@ -1,8 +1,21 @@
1
- /*
2
- * ----------------------------------------------------------------------------
3
- * "THE BEER-WARE LICENSE" (Revision 42):
4
- * <mak@panter.ch> wrote this file. As long as you retain this notice you
5
- * can do whatever you want with this stuff. If we meet some day, and you think
6
- * this stuff is worth it, you can buy me a beer in return.
7
- * ----------------------------------------------------------------------------
8
- */
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2015-2016 Markus Koller
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
data/README.md CHANGED
@@ -1,46 +1,49 @@
1
1
  # Panter Rails Deploy
2
2
 
3
- This gem sets up everything you need to deploy your application on the Panter rails hosting:
3
+ This gem sets up everything you need to deploy your application on the Panter Rails hosting:
4
4
 
5
- - capistrano 3
6
- - unicorn
7
- - rbenv
8
- - dotenv
9
- - therubyracer
5
+ - [Capistrano 3](https://github.com/capistrano/capistrano) setup for:
6
+ - [Rails](https://github.com/capistrano/rails)
7
+ - [Bundler](https://github.com/capistrano/bundler)
8
+ - [rbenv](https://github.com/capistrano/rbenv)
9
+ - [ruby-install](https://github.com/capistrano-plugins/capistrano-rbenv-install)
10
+ - [unicorn-rails](https://github.com/samuelkadolph/unicorn-rails)
11
+ - [dotenv-rails](https://github.com/bkeepers/dotenv)
12
+ - [therubyracer](https://github.com/cowboyd/therubyracer) for [ExecJS](https://github.com/rails/execjs), used for asset compilation on the server
10
13
 
11
14
  ## How to use
12
15
 
13
- - Add to your Gemfile (global, not in a group):
16
+ - Add to your Gemfile **(globally, not in a group)**:
14
17
  ```ruby
15
18
  gem 'panter-rails-deploy'
16
19
  ```
17
20
 
18
- - Capify your project (Bundler is required here, [rbenv-binstubs](https://github.com/ianheggie/rbenv-binstubs) is recommended):
21
+ - Capify your project (`bundle exec` is required here, unless you use [rbenv-binstubs](https://github.com/ianheggie/rbenv-binstubs)):
19
22
  ```sh
20
23
  bundle exec cap install
21
24
  ```
22
25
 
23
- - Add one of these to your `Capfile` - below the line 'Include tasks from other gems included in your Gemfile':
26
+ - Add one of these to your `Capfile` - below the line "Include tasks from other gems included in your Gemfile":
24
27
 
25
- For rails projects with asset compilation
28
+ For a standard Rails project with asset compilation:
26
29
 
27
30
  ```ruby
28
31
  require 'panter-rails-deploy'
29
32
  ```
30
33
 
31
- For rails projects without asset compilation
34
+ For a Rails project that doesn't use asset compilation:
32
35
 
33
36
  ```ruby
34
37
  require 'panter-rails-deploy/without-assets'
35
38
  ```
36
39
 
37
- For other Rack applications
40
+ For other Rack applications:
38
41
 
39
42
  ```ruby
40
43
  require 'panter-rails-deploy/without-rails'
41
44
  ```
42
45
 
43
- - Set `:application` and `:repo_url` in `config/deploy.rb`
46
+ - Set `:application` and `:repo_url` in `config/deploy.rb` (note that in previous Capistrano versions it was called `:repository` instead)
44
47
 
45
48
  - Set up your stages in `config/deploy` folder (e.g. `config/deploy/production.rb`):
46
49
  ```ruby
@@ -56,12 +59,16 @@ This gem sets up everything you need to deploy your application on the Panter ra
56
59
 
57
60
  ## dotenv setup
58
61
 
59
- This is optional, but recommended:
62
+ Using `dotenv` is the [recommended approach](http://12factor.net/config) to store sensitive configuration in the environment instead of code repositories.
60
63
 
61
64
  - Add a file on your servers in `/home/app/app/shared/.env` with your keys:
62
65
  ```sh
63
- RAILS_SECRET_KEY_BASE: ...
66
+ RAILS_SECRET_KEY_BASE: 89d20f0...
64
67
  ```
68
+
69
+ - You can add any other key-value pairs, they'll simply be injected into `ENV`
70
+ - You can use `rake secret` / `rails secret` (Rails 5) to generate a new secure key
71
+ - Rails uses `SECRET_KEY_BASE` by default, but adding a `RAILS_` prefix is recommended since `dotenv` itself is framework-agnostic
65
72
 
66
73
  - If you need keys in development as well, add `.env` locally and add it to `.gitignore`
67
74
 
@@ -75,3 +82,5 @@ This is optional, but recommended:
75
82
  ```ruby
76
83
  set :linked_files, fetch(:linked_files, []).push('.env')
77
84
  ```
85
+
86
+ - The `fetch(..., []).push(...)` approach is needed for `:linked_files` and `:linked_dirs` to keep the values added by this Gem
@@ -7,7 +7,7 @@ namespace :load do
7
7
  set :log_level, :info
8
8
 
9
9
  set :linked_files, %w[ config/database.yml ]
10
- set :linked_dirs, %w[ log tmp/cache ]
10
+ set :linked_dirs, %w[ log tmp/cache tmp/pids ]
11
11
 
12
12
  # Setup capistrano-rails
13
13
  set :rails_env, 'production'
@@ -1,13 +1,13 @@
1
1
  Gem::Specification.new do |gem|
2
2
  gem.name = 'panter-rails-deploy'
3
- gem.version = '1.0.6'
4
- gem.date = '2015-07-26'
3
+ gem.version = '1.2.0'
4
+ gem.date = '2016-02-11'
5
5
  gem.summary = 'Capistrano setup for Panter Rails Hosting'
6
6
  gem.authors = [ 'Markus Koller', 'Beat Seeliger' ]
7
7
  gem.email = 'mak@panter.ch'
8
8
  gem.homepage = 'https://github.com/panter/panter-rails-deploy'
9
- gem.license = 'Beerware'
10
- gem.required_ruby_version = '>= 1.9.3'
9
+ gem.license = 'MIT'
10
+ gem.required_ruby_version = '>= 2.0.0'
11
11
 
12
12
  gem.files = `git ls-files`.split($/)
13
13
  gem.require_paths = [ 'lib' ]
@@ -21,11 +21,6 @@ Gem::Specification.new do |gem|
21
21
  gem.add_dependency 'unicorn-rails'
22
22
  gem.add_dependency 'dotenv-rails'
23
23
 
24
- # work around problem with sshkit 1.8.0,
25
- # see https://github.com/capistrano/sshkit/issues/303
26
- # and https://github.com/capistrano/rbenv/pull/59
27
- gem.add_dependency 'sshkit', '~> 1.7.1'
28
-
29
24
  # Asset pipeline dependencies
30
25
  gem.add_dependency 'therubyracer'
31
26
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: panter-rails-deploy
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.6
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Markus Koller
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-07-26 00:00:00.000000000 Z
12
+ date: 2016-02-11 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: capistrano
@@ -109,20 +109,6 @@ dependencies:
109
109
  - - ">="
110
110
  - !ruby/object:Gem::Version
111
111
  version: '0'
112
- - !ruby/object:Gem::Dependency
113
- name: sshkit
114
- requirement: !ruby/object:Gem::Requirement
115
- requirements:
116
- - - "~>"
117
- - !ruby/object:Gem::Version
118
- version: 1.7.1
119
- type: :runtime
120
- prerelease: false
121
- version_requirements: !ruby/object:Gem::Requirement
122
- requirements:
123
- - - "~>"
124
- - !ruby/object:Gem::Version
125
- version: 1.7.1
126
112
  - !ruby/object:Gem::Dependency
127
113
  name: therubyracer
128
114
  requirement: !ruby/object:Gem::Requirement
@@ -156,7 +142,7 @@ files:
156
142
  - panter-rails-deploy.gemspec
157
143
  homepage: https://github.com/panter/panter-rails-deploy
158
144
  licenses:
159
- - Beerware
145
+ - MIT
160
146
  metadata: {}
161
147
  post_install_message:
162
148
  rdoc_options: []
@@ -166,7 +152,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
166
152
  requirements:
167
153
  - - ">="
168
154
  - !ruby/object:Gem::Version
169
- version: 1.9.3
155
+ version: 2.0.0
170
156
  required_rubygems_version: !ruby/object:Gem::Requirement
171
157
  requirements:
172
158
  - - ">="