dkdeploy-rails 0.5.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (48) hide show
  1. checksums.yaml +7 -0
  2. data/.arcconfig +9 -0
  3. data/.arclint +43 -0
  4. data/.gitignore +20 -0
  5. data/.rubocop.yml +20 -0
  6. data/.rvmrc +8 -0
  7. data/CHANGELOG.md +41 -0
  8. data/Gemfile +4 -0
  9. data/LICENSE +7 -0
  10. data/README.md +88 -0
  11. data/Rakefile +5 -0
  12. data/Vagrantfile +46 -0
  13. data/config/vm/cookbooks/dkdeploy/attributes/mysql.rb +3 -0
  14. data/config/vm/cookbooks/dkdeploy/metadata.rb +4 -0
  15. data/config/vm/cookbooks/dkdeploy/recipes/default.rb +42 -0
  16. data/dkdeploy-rails.gemspec +34 -0
  17. data/features/support/env.rb +2 -0
  18. data/lib/capistrano/dkdeploy/rails.rb +25 -0
  19. data/lib/dkdeploy.rb +1 -0
  20. data/lib/dkdeploy/rails/i18n.rb +10 -0
  21. data/lib/dkdeploy/rails/version.rb +15 -0
  22. data/spec/fixtures/application/.rvmrc +8 -0
  23. data/spec/fixtures/application/Capfile +8 -0
  24. data/spec/fixtures/application/Gemfile +9 -0
  25. data/spec/fixtures/application/Version +1 -0
  26. data/spec/fixtures/application/config/assets_exclude_file.txt +1 -0
  27. data/spec/fixtures/application/config/deploy.rb +10 -0
  28. data/spec/fixtures/application/config/deploy/dev.rb +24 -0
  29. data/spec/fixtures/application/config/etc/apache2/conf/.htaccess.erb +12 -0
  30. data/spec/fixtures/application/config/etc/apache2/conf/dev.htaccess.erb +3 -0
  31. data/spec/fixtures/application/config/preseed/default_content.sql.gz +0 -0
  32. data/spec/fixtures/application/config/preseed/default_structure.sql.gz +0 -0
  33. data/spec/fixtures/application/config/preseed/fileadmin.tar.gz +0 -0
  34. data/spec/fixtures/application/config/preseed/uploads.tar.gz +0 -0
  35. data/spec/fixtures/application/htdocs/.hidden/.gitkeep +0 -0
  36. data/spec/fixtures/application/htdocs/Gemfile +0 -0
  37. data/spec/fixtures/application/htdocs/bower.json +15 -0
  38. data/spec/fixtures/application/htdocs/catalog/.hidden/.gitkeep +0 -0
  39. data/spec/fixtures/application/htdocs/catalog/index.html +1 -0
  40. data/spec/fixtures/application/htdocs/index.html +1 -0
  41. data/spec/fixtures/application/htdocs/stylesheets/test1/config.rb +3 -0
  42. data/spec/fixtures/application/htdocs/stylesheets/test1/css/.gitkeep +0 -0
  43. data/spec/fixtures/application/htdocs/stylesheets/test1/src/source.scss +5 -0
  44. data/spec/fixtures/application/htdocs/stylesheets/test2/config.rb +3 -0
  45. data/spec/fixtures/application/htdocs/stylesheets/test2/css/.gitkeep +0 -0
  46. data/spec/fixtures/application/htdocs/stylesheets/test2/src/source.scss +5 -0
  47. data/spec/fixtures/application/temp/dkdeploy.sql.gz +0 -0
  48. metadata +287 -0
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 890293aad992454be944de9c55702f4abec1b8e8
4
+ data.tar.gz: e1b6a4dee2ac9c56a7d37545422b4b19a85f5a8a
5
+ SHA512:
6
+ metadata.gz: 90a60da539a7ddb73529e49cec7d4e3a2ab100e6c3806c2513aa73a240e5c7926b91a8e0a277d8b9504a9bdc0df78eb70a2620e88a9d86182cfdf3cb41ed9777
7
+ data.tar.gz: 9a0d4f19895b07c5552d7a596ad004b4af28b2e553f59ff0695f5050c41511e501423532fa57550f57ffe67796044f80b1d86b38ee51f1399413504a15e5b7a8
data/.arcconfig ADDED
@@ -0,0 +1,9 @@
1
+ {
2
+ "phabricator.uri": "https://phabricator.dkd.de/",
3
+ "project.name": "DKDPLYR",
4
+ "arc.feature.start.default": "develop",
5
+ "arc.land.onto.default": "develop",
6
+ "history.immutable": true,
7
+ "base": "git:merge-base(develop),arc:upstream",
8
+ "load": []
9
+ }
data/.arclint ADDED
@@ -0,0 +1,43 @@
1
+ {
2
+ "exclude": "(^tmp/)",
3
+ "linters": {
4
+ "ruby": {
5
+ "type": "ruby",
6
+ "include": "(\\.(rb|rake)$)",
7
+ "exclude": [
8
+ "(^spec/fixtures/application/htdocs/stylesheets/.*/config.rb)",
9
+ "(^config/vm/cookbooks/.*.rb)"
10
+ ],
11
+ "severity.rules": {
12
+ "/^warning/": "warning"
13
+ }
14
+ },
15
+ "rubocop": {
16
+ "type": "rubocop",
17
+ "include": "(\\.(rb|rake)$)",
18
+ "exclude": [
19
+ "(^spec/fixtures/application/htdocs/stylesheets/.*/config.rb)",
20
+ "(^config/vm/cookbooks/.*.rb)"
21
+ ]
22
+ },
23
+ "chmod": {
24
+ "type": "chmod"
25
+ },
26
+ "merge-conflict": {
27
+ "type": "merge-conflict"
28
+ },
29
+ "json": {
30
+ "type": "json",
31
+ "include": [
32
+ "(\\.json$)",
33
+ "(.arc*)"
34
+ ]
35
+ },
36
+ "xml": {
37
+ "type": "xml",
38
+ "include": [
39
+ "(\\.xml)"
40
+ ]
41
+ }
42
+ }
43
+ }
data/.gitignore ADDED
@@ -0,0 +1,20 @@
1
+ *.gem
2
+ *.rbc
3
+ .bundle
4
+ .config
5
+ .yardoc
6
+ InstalledFiles
7
+ _yardoc
8
+ coverage
9
+ doc/
10
+ lib/bundler/man
11
+ pkg
12
+ rdoc
13
+ spec/reports
14
+ test/tmp
15
+ test/version_tmp
16
+ tmp
17
+ .rakeTasks
18
+ .vagrant
19
+ .lock
20
+ Gemfile.lock
data/.rubocop.yml ADDED
@@ -0,0 +1,20 @@
1
+ AllCops:
2
+ Exclude:
3
+ - 'tmp/**/*'
4
+ - 'spec/fixtures/application/htdocs/stylesheets/**/config.rb'
5
+ - 'config/**/*'
6
+ - 'Vagrantfile'
7
+ GlobalVars:
8
+ AllowedVariables: []
9
+ MethodLength:
10
+ Max: 25
11
+ LineLength:
12
+ Max: 200
13
+ Style/TrailingCommaInLiteral:
14
+ Enabled: false
15
+ SpecialGlobalVars:
16
+ Enabled: false
17
+ BracesAroundHashParameters:
18
+ Enabled: false
19
+ CyclomaticComplexity:
20
+ Max: 10
data/.rvmrc ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+
3
+ # Define ruby version
4
+ rvm use ruby-2.1
5
+
6
+ # Define aliases
7
+ alias cucumber="bundle exec cucumber"
8
+ alias rubocop="bundle exec rubocop"
data/CHANGELOG.md ADDED
@@ -0,0 +1,41 @@
1
+ # dkdeploy-rails CHANGELOG
2
+
3
+ current version: v0.6.0 (2016-09-06)
4
+
5
+ ## version 0.6.0
6
+
7
+ ### additions
8
+
9
+ - set `:copy_source`
10
+ - set `:copy_exclude`
11
+
12
+ ### Bug fixes
13
+
14
+ - i18n issue for log messages
15
+
16
+ ## v0.5.0
17
+
18
+ - upgrade to dkdeploy-core v8.0+
19
+
20
+ ## v0.4.0
21
+
22
+ - do not overwrite i18n entries
23
+
24
+ ## 0.3.2
25
+
26
+ - revert i18n experiment from 0.3.1
27
+
28
+ ## 0.3.1
29
+
30
+ - remove explicit dependency to capistrano-bundler
31
+ - try i18n fix
32
+
33
+ ## v0.3.0
34
+
35
+ - supports dkdeploy-core v7.0.1
36
+
37
+ ## changes since v0.0.1
38
+
39
+ ### features
40
+
41
+ - depend on several Capistrano gems and dkdeploy-core v6.0.1
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source 'https://rubygems.dkd.de'
2
+
3
+ # Specify your gem's dependencies in dkdeploy-core.gemspec
4
+ gemspec
data/LICENSE ADDED
@@ -0,0 +1,7 @@
1
+ Copyright (c) 2016 dkd Internet Service GmbH, Frankfurt am Main (Germany)
2
+
3
+ Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
4
+
5
+ The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
6
+
7
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,88 @@
1
+ # Dkdeploy::Rails
2
+
3
+ ## Description
4
+
5
+ This Rubygem `dkdeploy` represents the extension of [Capistrano](http://capistranorb.com/) tasks directed to advanced Rails deployment processes.
6
+
7
+ ## Installation
8
+
9
+ Add this line to your application's `Gemfile`
10
+
11
+ gem 'dkdeploy-rails', '~> 1.0'
12
+
13
+ and then execute
14
+
15
+ bundle install
16
+
17
+ or install it yourself as
18
+
19
+ gem install dkdeploy-rails
20
+
21
+ ## Usage
22
+
23
+ Run in your project root
24
+
25
+ bundle exec cap install STAGES='dev,integration,testing,production'
26
+
27
+ This command will create the following Capistrano file structure with all the standard pre-configured constants.
28
+ Please be aware of the difference to the [native installation](http://capistranorb.com/documentation/getting-started/preparing-your-application/) of Capistrano.
29
+ Certainly you have to adjust `config/deploy.rb` and respective stages and customize them for your needs.
30
+
31
+ <pre>
32
+ ├── Capfile
33
+ └── config
34
+ ├── deploy
35
+ │ ├── dev.rb
36
+ │ ├── integration.rb
37
+ │ ├── testing.rb
38
+ │ └── production.rb
39
+ └── deploy.rb
40
+ </pre>
41
+
42
+ As next you have to append the following line to the `Capfile` in order to make use of dkdeploy extensions in addition to the standard Capistrano tasks:
43
+
44
+ require 'capistrano/dkdeploy/rails'
45
+
46
+ To convince yourself, that Capistrano tasks list has been extended, please run
47
+
48
+ cap -T
49
+
50
+ Please note, that dkdeploy uses the local copy strategy and overwrites the `:scm` constant. If you want to use it,
51
+ you should do nothing more. However if you want to change it, for example to `:git`, please add the following line to `deploy.rb`
52
+
53
+ set :scm, :git
54
+
55
+ For more information about available Capistrano constants please use the [Capistrano documentation](http://capistranorb.com/documentation/getting-started/preparing-your-application/).
56
+ The complete list of the dkdeploy constants you find on [project wiki page](https://redmine.dkd.de/projects/dkdeploy/wiki/Gem_dkdeploy-core).
57
+
58
+ ## Testing
59
+
60
+ ### Prerequisite
61
+
62
+ rvm (v1.25.x) with installed Ruby 2.1.
63
+
64
+ Add the virtual box alias to your `hosts` file
65
+
66
+ 192.168.156.180 dkdeploy.dev
67
+
68
+ ### Running tests
69
+
70
+ 1. Starting the local box (`vagrant up --provision`)
71
+ 2. Checking coding styles (`rubocop`)
72
+ 3. Running BDD cucumber tests (`cucumber`)
73
+
74
+ ## Contributing
75
+
76
+ 1. Install [git flow](https://github.com/nvie/gitflow)
77
+ 2. Install [Homebrew](http://brew.sh/) and run `brew install mysql-connector-c`
78
+ 3. Install [arcanist](https://secure.phabricator.com/book/phabricator/article/arcanist/)
79
+ 4. Install [NodeJS](https://nodejs.org) (supported: v0.12.7) via `brew install nodejs`
80
+ 5. Install [Bower](http://bower.io) (supported: v1.5.2) via `npm install -g bower@1.5.2`
81
+ 6. If project is not checked out already do git clone `git clone ssh://git@git.dkd.de:5522/diffusion/DKDPLYR/dkdeploy-rails.git`
82
+ 7. Checkout origin develop branch (`git checkout --track -b develop origin/develop`)
83
+ 8. Git flow initialze `git flow init -d`
84
+ 9. Installing gems `bundle install`
85
+ 10. Create new feature branch (`git flow feature start my-new-feature`)
86
+ 11. Run tests (README.md Testing)
87
+ 12. Commit your changes (`git commit -am 'Add some feature'`)
88
+ 13. Send changes to code review (`arc diff`)
data/Rakefile ADDED
@@ -0,0 +1,5 @@
1
+ task default: :spec
2
+ require 'bundler/gem_tasks'
3
+
4
+ require 'rspec/core/rake_task'
5
+ RSpec::Core::RakeTask.new
data/Vagrantfile ADDED
@@ -0,0 +1,46 @@
1
+ # Define path to local chef cookbook and roles repository path
2
+ if ENV['VAGRANT_CHEF_REPOSITORY_PATH'] && Dir.exist?(ENV['VAGRANT_CHEF_REPOSITORY_PATH'])
3
+ vagrant_chef_repository_path = ENV['VAGRANT_CHEF_REPOSITORY_PATH']
4
+ else
5
+ vagrant_chef_repository_path = '~/chef-repo-vagrant'
6
+ end
7
+
8
+ Vagrant.configure('2') do |config|
9
+
10
+ config.vm.box = 'ubuntu-12-04-server-amd64'
11
+ config.vm.box_url = 'http://vagrant.dkd.lan/boxes/v2/ubuntu-12-04-server-amd64.box'
12
+
13
+ config.vm.define 'master', primary: true do |master_config|
14
+
15
+ master_config.vm.network 'private_network', ip: '192.168.156.180'
16
+
17
+ master_config.vm.provision :chef_solo do |chef|
18
+ chef.cookbooks_path = [File.join(vagrant_chef_repository_path, 'cookbooks'), 'config/vm/cookbooks']
19
+ chef.roles_path = [File.join(vagrant_chef_repository_path, 'roles')]
20
+
21
+ chef.add_role 'apt-cacher-client'
22
+ chef.add_role 'vagrant'
23
+ chef.add_role 'ubuntu'
24
+
25
+ chef.add_recipe 'dkdeploy'
26
+
27
+ chef.log_level = :info
28
+
29
+ # Specify custom JSON attributes:
30
+ chef.json = {}
31
+ end
32
+
33
+ # Memory limit and name of VirtualBox
34
+ master_config.vm.provider 'virtualbox' do |virtualbox|
35
+ virtualbox.gui = ENV['ENABLE_GUI_MODE'] && ENV['ENABLE_GUI_MODE'] =~ /^(true|yes|y|1)$/i ? true : false
36
+ virtualbox.customize [
37
+ 'modifyvm', :id,
38
+ '--natdnsproxy1', 'off',
39
+ '--natdnshostresolver1', 'on',
40
+ '--memory', '1024',
41
+ '--name', 'dkdeploy'
42
+ ]
43
+ end
44
+
45
+ end
46
+ end
@@ -0,0 +1,3 @@
1
+ set_unless['mysql']['server_root_password'] = 'jim-jack-bi'
2
+ set_unless['mysql']['bind_address'] = '0.0.0.0'
3
+ set_unless['mysql']['allow_remote_root'] = true
@@ -0,0 +1,4 @@
1
+ maintainer 'dkd Internet Service GmbH'
2
+ license 'GPL-3'
3
+ description 'Project cookbook'
4
+ version '0.1.0'
@@ -0,0 +1,42 @@
1
+ # Create unix user for tests
2
+ user 'test-user' do
3
+ action :create
4
+ end
5
+
6
+ group 'test-group' do
7
+ action :create
8
+ append true
9
+ members 'test-user'
10
+ end
11
+
12
+ # install apache2-utils. It is needed for the assets:add_htpasswd task
13
+ package 'apache2-utils' do
14
+ action :install
15
+ end
16
+
17
+ # MySQL server
18
+ include_recipe 'mysql'
19
+ include_recipe 'mysql::server'
20
+ include_recipe 'mysql::flexiconf'
21
+ include_recipe 'database'
22
+
23
+ mysql_connection_info = {
24
+ :host => 'localhost',
25
+ :username => 'root',
26
+ :password => node['mysql']['server_root_password']
27
+ }
28
+
29
+ mysql_database_user 'root' do
30
+ connection mysql_connection_info
31
+ password node['mysql']['server_root_password']
32
+ host '%'
33
+ action :create
34
+ privileges [:all]
35
+ action :grant
36
+ end
37
+
38
+ mysql_database 'dkdeploy database' do
39
+ database 'dkdeploy'
40
+ action :create_db
41
+ password node['mysql']['server_root_password']
42
+ end
@@ -0,0 +1,34 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'dkdeploy/rails/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = 'dkdeploy-rails'
8
+ spec.version = Dkdeploy::Rails::Version
9
+ spec.license = 'MIT'
10
+ spec.authors = ['Nicolai Reuschling', 'Michael Skrynski']
11
+ spec.email = ['nicolai.reuschling@dkd.de', 'michael.skrynski@dkd.de']
12
+ spec.description = 'dkd Rails deployment tasks and strategies'
13
+ spec.summary = 'dkd Rails deployment tasks and strategies'
14
+ spec.homepage = 'https://redmine.dkd.de/projects/dkdeploy/wiki'
15
+
16
+ spec.files = `git ls-files`.split($/)
17
+ spec.executables = spec.files.grep(%r{^bin\/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)\/})
19
+ spec.require_paths = ['lib']
20
+
21
+ spec.add_development_dependency 'bundler', '~> 1.12.5'
22
+ spec.add_development_dependency 'rake', '~> 11.2'
23
+ spec.add_development_dependency 'rspec', '~> 3.5'
24
+ spec.add_development_dependency 'cucumber', '~> 2.4'
25
+ spec.add_development_dependency 'rubocop', '~> 0.42'
26
+ spec.add_development_dependency 'aruba', '~> 0.14.1'
27
+ spec.add_development_dependency 'pry', '~> 0.10.1'
28
+ spec.add_development_dependency 'dkdeploy-test_environment', '~> 1.0'
29
+
30
+ spec.add_dependency 'sshkit', '~> 1.10.0'
31
+ spec.add_dependency 'dkdeploy-core', '~> 8.0'
32
+ spec.add_dependency 'capistrano-rails', '~> 1.1'
33
+ spec.add_dependency 'capistrano-passenger', '~> 0.2'
34
+ end
@@ -0,0 +1,2 @@
1
+ require 'dkdeploy/test/application'
2
+ TEST_APPLICATION = Dkdeploy::Test::Application.new File.expand_path('../../../', __FILE__)
@@ -0,0 +1,25 @@
1
+ # Include dkdeploy gem
2
+ require 'dkdeploy'
3
+
4
+ require 'capistrano/dkdeploy/core'
5
+
6
+ # Passenger support for Capistrano
7
+ require 'capistrano/passenger'
8
+
9
+ require 'capistrano/bundler'
10
+ require 'capistrano/rails/assets'
11
+ require 'capistrano/rails/migrations'
12
+
13
+ include Capistrano::DSL
14
+
15
+ set :passenger_restart_with_touch, -> { fetch(:dkdeploy_passenger_restart_with_touch, true) }
16
+
17
+ namespace :load do
18
+ task :defaults do
19
+ set :use_sudo, false
20
+ set :copy_source, '.' # override the dkdeploy-core default 'htdocs'
21
+ set :copy_exclude, %w(.rspec .travis.yml .hidden **/.hidden **/.git) # override dkdeploy-core to include Gemfile
22
+ set :linked_dirs, %w(log tmp/pids tmp/cache tmp/sockets public/system public/assets uploads)
23
+ set :passenger_restart_with_touch, true
24
+ end
25
+ end
data/lib/dkdeploy.rb ADDED
@@ -0,0 +1 @@
1
+ require 'dkdeploy/rails/version'
@@ -0,0 +1,10 @@
1
+ require 'i18n'
2
+
3
+ # empty Hash so that we can call store_translations
4
+ en = {}
5
+
6
+ I18n.backend.store_translations(:en, dkdeploy: en)
7
+
8
+ if I18n.respond_to?(:enforce_available_locales=)
9
+ I18n.enforce_available_locales = true
10
+ end
@@ -0,0 +1,15 @@
1
+ module Dkdeploy
2
+ module Rails
3
+ # Class for version number
4
+ #
5
+ class Version
6
+ MAJOR = 0
7
+ MINOR = 5
8
+ PATCH = 0
9
+
10
+ def self.to_s
11
+ "#{MAJOR}.#{MINOR}.#{PATCH}"
12
+ end
13
+ end
14
+ end
15
+ end
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+
3
+ # Define ruby version
4
+ rvm use ruby-2.1
5
+
6
+ # Define aliases
7
+ alias cap="bundle exec cap"
8
+ alias compass="bundle exec compass"
@@ -0,0 +1,8 @@
1
+ # Load DSL and Setup Up Stages
2
+ require 'capistrano/setup'
3
+
4
+ # Includes default deployment tasks
5
+ require 'capistrano/deploy'
6
+
7
+ # Includes dkdeploy deployment tasks
8
+ require 'capistrano/dkdeploy/rails'
@@ -0,0 +1,9 @@
1
+ source 'https://rubygems.org'
2
+
3
+ gem 'dkdeploy-rails', path: '../../'
4
+
5
+ # Gem for task "assets:compile_compass"
6
+ gem 'compass', '~> 0.12.0'
7
+
8
+ # for debugging only
9
+ gem 'pry', '~> 0.10.0'
@@ -0,0 +1 @@
1
+ 1.0.0
@@ -0,0 +1 @@
1
+ should_be_excluded.txt
@@ -0,0 +1,10 @@
1
+ set :application, 'test_app'
2
+
3
+ SSHKit.config.command_map.prefix[:compass].push 'bundle exec'
4
+ SSHKit.config.command_map.prefix[:chown].push 'sudo'
5
+ SSHKit.config.command_map.prefix[:chgrp].push 'sudo'
6
+ SSHKit.config.command_map.prefix[:chmod].push 'sudo'
7
+
8
+ set :asset_folders, %w(fileadmin uploads)
9
+ set :asset_default_content, %w(fileadmin uploads)
10
+ set :asset_exclude_file, 'config/assets_exclude_file.txt'
@@ -0,0 +1,24 @@
1
+ set :deploy_to, '/home/vagrant/deploy'
2
+ server 'dkdeploy.dev', roles: %w(web app)
3
+
4
+ # no ssh compression on the dev stage
5
+ set :ssh_options, {
6
+ compression: 'none'
7
+ }
8
+
9
+ set :copy_source, 'htdocs'
10
+ set :copy_exclude, %w(
11
+ Gemfile*
12
+ .hidden
13
+ **/.hidden
14
+ )
15
+
16
+ # version file path
17
+ set :version_file_path, ''
18
+
19
+ # default file owner/group for dev stage
20
+ set :default_file_access_owner_of_shared_path, 'vagrant'
21
+ set :default_file_access_owner_of_release_path, 'vagrant'
22
+
23
+ set :default_file_access_group_of_shared_path, 'vagrant'
24
+ set :default_file_access_group_of_release_path, 'vagrant'
@@ -0,0 +1,12 @@
1
+ <FilesMatch "index.php">
2
+ Allow from all
3
+ </FilesMatch>
4
+ <%=
5
+ current_stage = fetch(:stage).to_s
6
+ current_stage_htaccess_file_configuration_path = current_stage + '.htaccess.erb'
7
+ sub_template_file_path = File.expand_path File.join(apache_configuration_path, current_stage_htaccess_file_configuration_path)
8
+ if File.exists? sub_template_file_path
9
+ sub_template = ERB.new File.read(sub_template_file_path)
10
+ sub_template.result
11
+ end
12
+ %>
@@ -0,0 +1,3 @@
1
+ <Files "favicon.ico">
2
+ Deny from all
3
+ </Files>
File without changes
File without changes
@@ -0,0 +1,15 @@
1
+ {
2
+ "name": "dkdeploy-core-bower-fixture-file",
3
+ "version": "0.0.1",
4
+ "authors": [
5
+ "Nicolai Reuschling <nicolai.reuschling@dkd.de>"
6
+ ],
7
+ "description": "This is a fixture bower.js file for dkdeploy-core",
8
+ "moduleType": [
9
+ "globals"
10
+ ],
11
+ "license": "MIT",
12
+ "dependencies": {
13
+ "jquery": "2.1.4"
14
+ }
15
+ }
@@ -0,0 +1 @@
1
+ Hello World
@@ -0,0 +1 @@
1
+ Hello World
@@ -0,0 +1,3 @@
1
+ project_type = :stand_alone
2
+ css_dir = 'css'
3
+ sass_dir = 'src'
@@ -0,0 +1,5 @@
1
+ ul {
2
+ li{
3
+ color: green;
4
+ }
5
+ }
@@ -0,0 +1,3 @@
1
+ project_type = :stand_alone
2
+ css_dir = 'css'
3
+ sass_dir = 'src'
@@ -0,0 +1,5 @@
1
+ ul {
2
+ li{
3
+ color: green;
4
+ }
5
+ }
metadata ADDED
@@ -0,0 +1,287 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: dkdeploy-rails
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.5.0
5
+ platform: ruby
6
+ authors:
7
+ - Nicolai Reuschling
8
+ - Michael Skrynski
9
+ autorequire:
10
+ bindir: bin
11
+ cert_chain: []
12
+ date: 2016-09-08 00:00:00.000000000 Z
13
+ dependencies:
14
+ - !ruby/object:Gem::Dependency
15
+ name: bundler
16
+ requirement: !ruby/object:Gem::Requirement
17
+ requirements:
18
+ - - "~>"
19
+ - !ruby/object:Gem::Version
20
+ version: 1.12.5
21
+ type: :development
22
+ prerelease: false
23
+ version_requirements: !ruby/object:Gem::Requirement
24
+ requirements:
25
+ - - "~>"
26
+ - !ruby/object:Gem::Version
27
+ version: 1.12.5
28
+ - !ruby/object:Gem::Dependency
29
+ name: rake
30
+ requirement: !ruby/object:Gem::Requirement
31
+ requirements:
32
+ - - "~>"
33
+ - !ruby/object:Gem::Version
34
+ version: '11.2'
35
+ type: :development
36
+ prerelease: false
37
+ version_requirements: !ruby/object:Gem::Requirement
38
+ requirements:
39
+ - - "~>"
40
+ - !ruby/object:Gem::Version
41
+ version: '11.2'
42
+ - !ruby/object:Gem::Dependency
43
+ name: rspec
44
+ requirement: !ruby/object:Gem::Requirement
45
+ requirements:
46
+ - - "~>"
47
+ - !ruby/object:Gem::Version
48
+ version: '3.5'
49
+ type: :development
50
+ prerelease: false
51
+ version_requirements: !ruby/object:Gem::Requirement
52
+ requirements:
53
+ - - "~>"
54
+ - !ruby/object:Gem::Version
55
+ version: '3.5'
56
+ - !ruby/object:Gem::Dependency
57
+ name: cucumber
58
+ requirement: !ruby/object:Gem::Requirement
59
+ requirements:
60
+ - - "~>"
61
+ - !ruby/object:Gem::Version
62
+ version: '2.4'
63
+ type: :development
64
+ prerelease: false
65
+ version_requirements: !ruby/object:Gem::Requirement
66
+ requirements:
67
+ - - "~>"
68
+ - !ruby/object:Gem::Version
69
+ version: '2.4'
70
+ - !ruby/object:Gem::Dependency
71
+ name: rubocop
72
+ requirement: !ruby/object:Gem::Requirement
73
+ requirements:
74
+ - - "~>"
75
+ - !ruby/object:Gem::Version
76
+ version: '0.42'
77
+ type: :development
78
+ prerelease: false
79
+ version_requirements: !ruby/object:Gem::Requirement
80
+ requirements:
81
+ - - "~>"
82
+ - !ruby/object:Gem::Version
83
+ version: '0.42'
84
+ - !ruby/object:Gem::Dependency
85
+ name: aruba
86
+ requirement: !ruby/object:Gem::Requirement
87
+ requirements:
88
+ - - "~>"
89
+ - !ruby/object:Gem::Version
90
+ version: 0.14.1
91
+ type: :development
92
+ prerelease: false
93
+ version_requirements: !ruby/object:Gem::Requirement
94
+ requirements:
95
+ - - "~>"
96
+ - !ruby/object:Gem::Version
97
+ version: 0.14.1
98
+ - !ruby/object:Gem::Dependency
99
+ name: pry
100
+ requirement: !ruby/object:Gem::Requirement
101
+ requirements:
102
+ - - "~>"
103
+ - !ruby/object:Gem::Version
104
+ version: 0.10.1
105
+ type: :development
106
+ prerelease: false
107
+ version_requirements: !ruby/object:Gem::Requirement
108
+ requirements:
109
+ - - "~>"
110
+ - !ruby/object:Gem::Version
111
+ version: 0.10.1
112
+ - !ruby/object:Gem::Dependency
113
+ name: dkdeploy-test_environment
114
+ requirement: !ruby/object:Gem::Requirement
115
+ requirements:
116
+ - - "~>"
117
+ - !ruby/object:Gem::Version
118
+ version: '1.0'
119
+ type: :development
120
+ prerelease: false
121
+ version_requirements: !ruby/object:Gem::Requirement
122
+ requirements:
123
+ - - "~>"
124
+ - !ruby/object:Gem::Version
125
+ version: '1.0'
126
+ - !ruby/object:Gem::Dependency
127
+ name: sshkit
128
+ requirement: !ruby/object:Gem::Requirement
129
+ requirements:
130
+ - - "~>"
131
+ - !ruby/object:Gem::Version
132
+ version: 1.10.0
133
+ type: :runtime
134
+ prerelease: false
135
+ version_requirements: !ruby/object:Gem::Requirement
136
+ requirements:
137
+ - - "~>"
138
+ - !ruby/object:Gem::Version
139
+ version: 1.10.0
140
+ - !ruby/object:Gem::Dependency
141
+ name: dkdeploy-core
142
+ requirement: !ruby/object:Gem::Requirement
143
+ requirements:
144
+ - - "~>"
145
+ - !ruby/object:Gem::Version
146
+ version: '8.0'
147
+ type: :runtime
148
+ prerelease: false
149
+ version_requirements: !ruby/object:Gem::Requirement
150
+ requirements:
151
+ - - "~>"
152
+ - !ruby/object:Gem::Version
153
+ version: '8.0'
154
+ - !ruby/object:Gem::Dependency
155
+ name: capistrano-rails
156
+ requirement: !ruby/object:Gem::Requirement
157
+ requirements:
158
+ - - "~>"
159
+ - !ruby/object:Gem::Version
160
+ version: '1.1'
161
+ type: :runtime
162
+ prerelease: false
163
+ version_requirements: !ruby/object:Gem::Requirement
164
+ requirements:
165
+ - - "~>"
166
+ - !ruby/object:Gem::Version
167
+ version: '1.1'
168
+ - !ruby/object:Gem::Dependency
169
+ name: capistrano-passenger
170
+ requirement: !ruby/object:Gem::Requirement
171
+ requirements:
172
+ - - "~>"
173
+ - !ruby/object:Gem::Version
174
+ version: '0.2'
175
+ type: :runtime
176
+ prerelease: false
177
+ version_requirements: !ruby/object:Gem::Requirement
178
+ requirements:
179
+ - - "~>"
180
+ - !ruby/object:Gem::Version
181
+ version: '0.2'
182
+ description: dkd Rails deployment tasks and strategies
183
+ email:
184
+ - nicolai.reuschling@dkd.de
185
+ - michael.skrynski@dkd.de
186
+ executables: []
187
+ extensions: []
188
+ extra_rdoc_files: []
189
+ files:
190
+ - ".arcconfig"
191
+ - ".arclint"
192
+ - ".gitignore"
193
+ - ".rubocop.yml"
194
+ - ".rvmrc"
195
+ - CHANGELOG.md
196
+ - Gemfile
197
+ - LICENSE
198
+ - README.md
199
+ - Rakefile
200
+ - Vagrantfile
201
+ - config/vm/cookbooks/dkdeploy/attributes/mysql.rb
202
+ - config/vm/cookbooks/dkdeploy/metadata.rb
203
+ - config/vm/cookbooks/dkdeploy/recipes/default.rb
204
+ - dkdeploy-rails.gemspec
205
+ - features/support/env.rb
206
+ - lib/capistrano/dkdeploy/rails.rb
207
+ - lib/dkdeploy.rb
208
+ - lib/dkdeploy/rails/i18n.rb
209
+ - lib/dkdeploy/rails/version.rb
210
+ - spec/fixtures/application/.rvmrc
211
+ - spec/fixtures/application/Capfile
212
+ - spec/fixtures/application/Gemfile
213
+ - spec/fixtures/application/Version
214
+ - spec/fixtures/application/config/assets_exclude_file.txt
215
+ - spec/fixtures/application/config/deploy.rb
216
+ - spec/fixtures/application/config/deploy/dev.rb
217
+ - spec/fixtures/application/config/etc/apache2/conf/.htaccess.erb
218
+ - spec/fixtures/application/config/etc/apache2/conf/dev.htaccess.erb
219
+ - spec/fixtures/application/config/preseed/default_content.sql.gz
220
+ - spec/fixtures/application/config/preseed/default_structure.sql.gz
221
+ - spec/fixtures/application/config/preseed/fileadmin.tar.gz
222
+ - spec/fixtures/application/config/preseed/uploads.tar.gz
223
+ - spec/fixtures/application/htdocs/.hidden/.gitkeep
224
+ - spec/fixtures/application/htdocs/Gemfile
225
+ - spec/fixtures/application/htdocs/bower.json
226
+ - spec/fixtures/application/htdocs/catalog/.hidden/.gitkeep
227
+ - spec/fixtures/application/htdocs/catalog/index.html
228
+ - spec/fixtures/application/htdocs/index.html
229
+ - spec/fixtures/application/htdocs/stylesheets/test1/config.rb
230
+ - spec/fixtures/application/htdocs/stylesheets/test1/css/.gitkeep
231
+ - spec/fixtures/application/htdocs/stylesheets/test1/src/source.scss
232
+ - spec/fixtures/application/htdocs/stylesheets/test2/config.rb
233
+ - spec/fixtures/application/htdocs/stylesheets/test2/css/.gitkeep
234
+ - spec/fixtures/application/htdocs/stylesheets/test2/src/source.scss
235
+ - spec/fixtures/application/temp/dkdeploy.sql.gz
236
+ homepage: https://redmine.dkd.de/projects/dkdeploy/wiki
237
+ licenses:
238
+ - MIT
239
+ metadata: {}
240
+ post_install_message:
241
+ rdoc_options: []
242
+ require_paths:
243
+ - lib
244
+ required_ruby_version: !ruby/object:Gem::Requirement
245
+ requirements:
246
+ - - ">="
247
+ - !ruby/object:Gem::Version
248
+ version: '0'
249
+ required_rubygems_version: !ruby/object:Gem::Requirement
250
+ requirements:
251
+ - - ">="
252
+ - !ruby/object:Gem::Version
253
+ version: '0'
254
+ requirements: []
255
+ rubyforge_project:
256
+ rubygems_version: 2.6.6
257
+ signing_key:
258
+ specification_version: 4
259
+ summary: dkd Rails deployment tasks and strategies
260
+ test_files:
261
+ - features/support/env.rb
262
+ - spec/fixtures/application/.rvmrc
263
+ - spec/fixtures/application/Capfile
264
+ - spec/fixtures/application/Gemfile
265
+ - spec/fixtures/application/Version
266
+ - spec/fixtures/application/config/assets_exclude_file.txt
267
+ - spec/fixtures/application/config/deploy.rb
268
+ - spec/fixtures/application/config/deploy/dev.rb
269
+ - spec/fixtures/application/config/etc/apache2/conf/.htaccess.erb
270
+ - spec/fixtures/application/config/etc/apache2/conf/dev.htaccess.erb
271
+ - spec/fixtures/application/config/preseed/default_content.sql.gz
272
+ - spec/fixtures/application/config/preseed/default_structure.sql.gz
273
+ - spec/fixtures/application/config/preseed/fileadmin.tar.gz
274
+ - spec/fixtures/application/config/preseed/uploads.tar.gz
275
+ - spec/fixtures/application/htdocs/.hidden/.gitkeep
276
+ - spec/fixtures/application/htdocs/Gemfile
277
+ - spec/fixtures/application/htdocs/bower.json
278
+ - spec/fixtures/application/htdocs/catalog/.hidden/.gitkeep
279
+ - spec/fixtures/application/htdocs/catalog/index.html
280
+ - spec/fixtures/application/htdocs/index.html
281
+ - spec/fixtures/application/htdocs/stylesheets/test1/config.rb
282
+ - spec/fixtures/application/htdocs/stylesheets/test1/css/.gitkeep
283
+ - spec/fixtures/application/htdocs/stylesheets/test1/src/source.scss
284
+ - spec/fixtures/application/htdocs/stylesheets/test2/config.rb
285
+ - spec/fixtures/application/htdocs/stylesheets/test2/css/.gitkeep
286
+ - spec/fixtures/application/htdocs/stylesheets/test2/src/source.scss
287
+ - spec/fixtures/application/temp/dkdeploy.sql.gz