This repository has been archived by the owner on Mar 5, 2019. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 9
Capistrano subdir configuration #155
Open
JohnSmall
wants to merge
7
commits into
HackBrexit:capistrano_subdir_configuration
Choose a base branch
from
JohnSmall:capistrano_subdir_configuration
base: capistrano_subdir_configuration
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
7 commits
Select commit
Hold shift + click to select a range
860a557
updates for deploying a subtree
8519935
added rack_cors gem to Gemfile
866f391
change unicorn socket
d753335
updated unicorn configuration
43fadda
Argg! too much time working on sysops for Unicorn, switching to Passe…
4f1662e
removed references to unicorn
404993f
use ruby 2.4.0
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
ruby-2.3.1 | ||
ruby-2.4.0 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,8 @@ | ||
# config valid only for Capistrano 3.1 | ||
# See http://stackoverflow.com/questions/29168/deploying-a-git-subdirectory-in-capistrano/6969505#6969505 for instructions on how | ||
# to install from a subdirection | ||
# As of Capistrano 3.3.3, you can now use the :repo_tree configuration variable, | ||
# http://capistranorb.com/documentation/getting-started/configuration/ | ||
lock '3.6.1' | ||
set :application, ->{YAML.load_file('config/deploy.yml')[fetch(:stage)][:directory]} | ||
set :repo_url, ->{YAML.load_file('config/deploy.yml')[fetch(:stage)][:repo_url]} | ||
|
@@ -8,11 +12,10 @@ | |
# ask :branch, proc { `git rev-parse --abbrev-ref HEAD`.chomp }.call | ||
|
||
# Default deploy_to directory is /var/www/my_app | ||
set :deploy_to, "/home/rails/muti/#{fetch(:stage)}" | ||
set :deploy_to, "/home/rails/muti_tree/#{fetch(:stage)}" | ||
|
||
# Default value for :scm is :git | ||
# set :scm, :git | ||
set :git_strategy, Capistrano::Git::SubmoduleStrategy | ||
set :repo_tree, 'src/ruby/meetings' | ||
# Default value for :format is :pretty | ||
# set :format, :pretty | ||
|
@@ -24,7 +27,7 @@ | |
# set :pty, true | ||
|
||
# Default value for :linked_files is [] | ||
set :linked_files, ['config/database.yml','config/secrets.yml','config/deploy.yml','config/environment_params.yml'] | ||
set :linked_files, ['config/database.yml','config/secrets.yml','config/environment_params.yml'] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Space missing after comma. |
||
|
||
# Default value for linked_dirs is [] | ||
set :linked_dirs, %w{bin log tmp/pids tmp/cache tmp/sockets vendor/bundle public/system public/uploads} | ||
|
@@ -35,24 +38,5 @@ | |
# Default value for keep_releases is 5 | ||
# set :keep_releases, 5 | ||
|
||
namespace :deploy do | ||
desc 'Restart application' | ||
task :restart do | ||
on roles(:app), in: :sequence, wait: 5 do | ||
# Your restart mechanism here, for example: | ||
invoke 'unicorn:reload' | ||
end | ||
end | ||
after :publishing, :restart | ||
|
||
after :restart, :clear_cache do | ||
on roles(:web), in: :groups, limit: 3, wait: 10 do | ||
# Here we can do anything such as: | ||
# within release_path do | ||
# execute :rake, 'cache:clear' | ||
# end | ||
end | ||
end | ||
|
||
|
||
end | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -16,7 +16,7 @@ | |
# server list. The second argument is a, or duck-types, Hash and is | ||
# used to set extended properties on the server. | ||
set :domain,YAML.load_file('config/deploy.yml')[fetch(:stage)][:domain] | ||
server fetch(:domain), user: 'ubuntu', roles: %w{db web app}#, my_property: :my_value | ||
server fetch(:domain), user: 'rails', roles: %w{db web app}#, my_property: :my_value | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. %w-literals should be delimited by ( and ). |
||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Line is too long. [129/80]
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
im ok with that