capistrano-rails-console 2.0.0 → 2.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +7 -1
- data/README.md +10 -5
- data/lib/capistrano-rails-console.rb +0 -1
- data/lib/capistrano/rails/console.rb +3 -1
- data/lib/capistrano/rails/console/{tasks/remote.cap → tasks.cap} +11 -0
- data/lib/capistrano/rails/console/version.rb +1 -1
- metadata +3 -4
- data/lib/capistrano/rails/console/remote.rb +0 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 24afc868db18013827cff21ba79338acba73c220
|
4
|
+
data.tar.gz: e3a55356b9671dcf01c7317f307395b3dc026a51
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 01377580057b65a2f5848317d0898ae5254eefb20b18f29d4329975408576d84372c616bcb06a73cbfb147df8c0f2832ae12544603e610c3060f20d3fd78a046
|
7
|
+
data.tar.gz: 4dec52fcf68762eb6d4f5e91a51a1ecacb10a8ab7286940ae16d06cfcffe7ef82a19fb7b77e13603d051e3be04ae9c767fe581db076f27f17574e13cba7ee067
|
data/CHANGELOG.md
CHANGED
@@ -1,9 +1,15 @@
|
|
1
1
|
# Change Log
|
2
2
|
|
3
|
+
## 2.1.0 (2016-09-23)
|
4
|
+
### Feature
|
5
|
+
- add support for `rails dbconsole`
|
6
|
+
### Fixed
|
7
|
+
- revert unintentional change when the gem is required
|
8
|
+
|
3
9
|
## 2.0.0 (2016-09-16)
|
4
10
|
### Changed
|
5
11
|
- switched connection part to _sshkit-interactive_
|
6
|
-
- allow setting rails environment separately deployment environment
|
12
|
+
- allow setting rails environment separately from deployment environment
|
7
13
|
- allow setting user to run rails console separately from ssh user
|
8
14
|
|
9
15
|
## 1.0.2 (2015-12-06)
|
data/README.md
CHANGED
@@ -7,7 +7,7 @@
|
|
7
7
|
|
8
8
|
# Capistrano::Rails::Console
|
9
9
|
|
10
|
-
Remote rails console for capistrano.
|
10
|
+
Remote rails console and dbconsole for capistrano.
|
11
11
|
|
12
12
|
|
13
13
|
## Installation
|
@@ -15,7 +15,7 @@ Remote rails console for capistrano.
|
|
15
15
|
Add this line to your application's Gemfile:
|
16
16
|
|
17
17
|
```ruby
|
18
|
-
gem 'capistrano-rails-console'
|
18
|
+
gem 'capistrano-rails-console', require: false
|
19
19
|
```
|
20
20
|
|
21
21
|
And then execute:
|
@@ -35,7 +35,7 @@ Require in `Capfile` to use the default task:
|
|
35
35
|
require 'capistrano/rails/console'
|
36
36
|
```
|
37
37
|
|
38
|
-
|
38
|
+
Run a remote rails console with:
|
39
39
|
|
40
40
|
$ cap production rails:console
|
41
41
|
|
@@ -43,18 +43,23 @@ You can also start a sandbox session:
|
|
43
43
|
|
44
44
|
$ cap production rails:console sandbox=1
|
45
45
|
|
46
|
+
Or run a dbconsole:
|
47
|
+
|
48
|
+
$ cap production rails:dbconsole
|
49
|
+
|
46
50
|
## Options
|
47
51
|
|
48
52
|
### Rails environment
|
49
53
|
|
50
54
|
```ruby
|
51
|
-
set :console_env, :production
|
55
|
+
set :console_env, :production # use different environment than deployment environment (rails_env)
|
52
56
|
```
|
53
57
|
|
54
58
|
### User
|
55
59
|
|
56
60
|
```ruby
|
57
|
-
set :console_user, :appuser
|
61
|
+
set :console_user, :appuser # run rails console as appuser through sudo
|
62
|
+
set :console_user, nil # explicitly disable switching user through sudo
|
58
63
|
```
|
59
64
|
|
60
65
|
|
@@ -1 +0,0 @@
|
|
1
|
-
require 'capistrano/rails/console'
|
@@ -23,4 +23,15 @@ namespace :rails do
|
|
23
23
|
end
|
24
24
|
end
|
25
25
|
end
|
26
|
+
|
27
|
+
desc 'Interact with a remote rails dbconsole'
|
28
|
+
task :dbconsole do
|
29
|
+
run_interactively primary(:app) do
|
30
|
+
within current_path do
|
31
|
+
as user: fetch(:console_user) do
|
32
|
+
execute(:rails, :dbconsole, '-e', fetch(:console_env))
|
33
|
+
end
|
34
|
+
end
|
35
|
+
end
|
36
|
+
end
|
26
37
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: capistrano-rails-console
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.
|
4
|
+
version: 2.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Florian Schwab
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-09-
|
11
|
+
date: 2016-09-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: capistrano
|
@@ -88,8 +88,7 @@ files:
|
|
88
88
|
- capistrano-rails-console.gemspec
|
89
89
|
- lib/capistrano-rails-console.rb
|
90
90
|
- lib/capistrano/rails/console.rb
|
91
|
-
- lib/capistrano/rails/console/
|
92
|
-
- lib/capistrano/rails/console/tasks/remote.cap
|
91
|
+
- lib/capistrano/rails/console/tasks.cap
|
93
92
|
- lib/capistrano/rails/console/version.rb
|
94
93
|
homepage: https://github.com/ydkn/capistrano-rails-console
|
95
94
|
licenses:
|