Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
C
capistrano-sneakers
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ikcrm_common
capistrano-sneakers
Commits
073fc04e
Unverified
Commit
073fc04e
authored
Jan 24, 2018
by
Tensho
Committed by
Andrew Babichev
Jan 26, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cleanup
parent
8665c70d
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
9 deletions
+6
-9
capistrano-sneakers.gemspec
+0
-1
lib/capistrano/tasks/sneakers.rake
+6
-8
No files found.
capistrano-sneakers.gemspec
View file @
073fc04e
# coding: utf-8
lib
=
File
.
expand_path
(
'../lib'
,
__FILE__
)
$LOAD_PATH
.
unshift
(
lib
)
unless
$LOAD_PATH
.
include?
(
lib
)
require
'capistrano/sneakers/version'
...
...
lib/capistrano/tasks/sneakers.rake
View file @
073fc04e
namespace
:load
do
task
:defaults
do
set
:sneakers_default_hooks
,
->
{
true
}
...
...
@@ -18,9 +17,7 @@ namespace :load do
end
end
namespace
:deploy
do
before
:starting
,
:check_sneakers_hooks
do
invoke
'sneakers:add_default_hooks'
if
fetch
(
:sneakers_default_hooks
)
end
...
...
@@ -31,7 +28,6 @@ namespace :deploy do
end
namespace
:sneakers
do
def
for_each_sneakers_process
(
reverse
=
false
,
&
block
)
pids
=
processes_sneakers_pids
pids
.
reverse!
if
reverse
...
...
@@ -155,9 +151,9 @@ namespace :sneakers do
end
task
:add_default_hooks
do
after
'deploy:starting'
,
'sneakers:quiet'
after
'deploy:updated'
,
'sneakers:stop'
after
'deploy:reverted'
,
'sneakers:stop'
after
'deploy:starting'
,
'sneakers:quiet'
after
'deploy:updated'
,
'sneakers:stop'
after
'deploy:reverted'
,
'sneakers:stop'
after
'deploy:published'
,
'sneakers:start'
end
...
...
@@ -196,7 +192,9 @@ namespace :sneakers do
on
roles
fetch
(
:sneakers_role
)
do
|
role
|
as_sneakers_user
(
role
)
do
for_each_sneakers_process
do
|
pid_file
,
idx
|
start_sneakers
(
pid_file
,
idx
)
unless
sneakers_pid_process_exists?
(
pid_file
)
unless
sneakers_pid_process_exists?
(
pid_file
)
start_sneakers
(
pid_file
,
idx
)
end
end
end
end
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment