Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Bao Nguyen
committed
Jul 25, 2014
1 parent
e222323
commit cf34be8
Showing
25 changed files
with
233 additions
and
87 deletions.
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 |
---|---|---|
@@ -0,0 +1,23 @@ | ||
AllCops: | ||
Include: | ||
- metadata.rb | ||
- Gemfile | ||
- attributes/** | ||
- recipes/** | ||
- libraries/** | ||
- providers/** | ||
- resources/** | ||
Exclude: | ||
- example/** | ||
- test/** | ||
- vendor/** | ||
|
||
Encoding: | ||
Enabled: false | ||
|
||
LineLength: | ||
Enabled: false | ||
|
||
WordArray: | ||
MinSize: 3 | ||
|
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
rvm: | ||
- 1.9.3 | ||
- 2.0.0 | ||
- 2.1.0 | ||
before_script: | ||
- bundle exec berks install | ||
script: | ||
- bundle exec rake test:quick | ||
|
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,7 +1,16 @@ | ||
source 'https://rubygems.org' | ||
|
||
gem 'test-kitchen', '~> 1.2.1' | ||
gem 'kitchen-vagrant', '= 0.15.0', :group => :integration | ||
gem 'kitchen-vagrant', '= 0.15.0', group: :integration | ||
gem 'librarian-chef' | ||
gem 'berkshelf' | ||
gem 'chef-zero' | ||
|
||
group 'develop' do | ||
gem 'kitchen-docker-api' | ||
gem 'rake' | ||
gem 'foodcritic', git: 'https://github.com/mlafeldt/foodcritic.git', branch: 'improve-rake-task' | ||
gem 'rubocop' | ||
gem 'knife-cookbook-doc' | ||
gem 'chefspec', '>= 3.2.0' | ||
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
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 |
---|---|---|
@@ -0,0 +1,73 @@ | ||
#!/usr/bin/env rake | ||
require 'rake' | ||
require 'rspec/core/rake_task' | ||
|
||
task :default => 'test:quick' | ||
|
||
namespace :test do | ||
|
||
RSpec::Core::RakeTask.new(:spec) do |t| | ||
t.pattern = Dir.glob('test/spec/**/*_spec.rb') | ||
t.rspec_opts = "--color -f d" | ||
end | ||
|
||
begin | ||
require 'kitchen/rake_tasks' | ||
Kitchen::RakeTasks.new | ||
rescue | ||
puts '>>>>> Kitchen gem not loaded, omitting tasks' unless ENV['CI'] | ||
end | ||
|
||
begin | ||
require 'foodcritic/rake_task' | ||
require 'foodcritic' | ||
task :default => [:foodcritic] | ||
FoodCritic::Rake::LintTask.new do |t| | ||
t.options = { | ||
fail_tags: %w/correctness services libraries deprecated/, | ||
exclude_paths: ['test/**/*', 'spec/**/*', 'features/**/*', 'example/**/*'] | ||
} | ||
end | ||
rescue LoadError | ||
warn "Foodcritic Is missing ZOMG" | ||
end | ||
|
||
begin | ||
require 'rubocop/rake_task' | ||
RuboCop::RakeTask.new do |task| | ||
task.fail_on_error = true | ||
task.options = %w{-D -a} | ||
end | ||
rescue LoadError | ||
warn "Rubocop gem not installed, now the code will look like crap!" | ||
end | ||
|
||
|
||
desc 'Run all of the quick tests.' | ||
task :quick do | ||
Rake::Task['test:rubocop'].invoke | ||
Rake::Task['test:foodcritic'].invoke | ||
Rake::Task['test:spec'].invoke | ||
end | ||
|
||
|
||
desc 'Run _all_ the tests. Go get a coffee.' | ||
task :complete do | ||
Rake::Task['test:quick'].invoke | ||
Rake::Task['test:kitchen:all'].invoke | ||
end | ||
|
||
desc 'Run CI tests' | ||
task :ci do | ||
Rake::Task['test:complete'].invoke | ||
end | ||
end | ||
|
||
|
||
namespace :release do | ||
task :update_metadata do | ||
end | ||
|
||
task :tag_release do | ||
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 |
---|---|---|
@@ -1,5 +1,5 @@ | ||
include_attribute "quagga" | ||
include_attribute 'quagga' | ||
|
||
default[:quagga][:bgp][:local_asn] = "" | ||
default[:quagga][:bgp][:local_asn] = '' | ||
default[:quagga][:bgp][:networks] = [] | ||
default[:quagga][:bgp][:peers] = {} |
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,6 +1,6 @@ | ||
include_attribute "quagga" | ||
include_attribute 'quagga' | ||
|
||
default[:quagga][:ospf][:area] = "" | ||
default[:quagga][:ospf][:area] = '' | ||
default[:quagga][:ospf][:networks] = [] | ||
default[:quagga][:ospf][:protocols] = [] | ||
default[:quagga][:ospf][:interfaces] = [] |
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,11 +1,7 @@ | ||
name "quagga" | ||
maintainer "Bao Nguyen" | ||
maintainer_email "ngqbao@gmail.com" | ||
license "All rights reserved" | ||
description "Generic Quagga cookbook" | ||
name 'quagga' | ||
maintainer 'Bao Nguyen' | ||
maintainer_email 'ngqbao@gmail.com' | ||
license 'All rights reserved' | ||
This comment has been minimized.
Sorry, something went wrong. |
||
description 'Generic Quagga cookbook' | ||
long_description IO.read(File.join(File.dirname(__FILE__), 'README.md')) | ||
version "0.1.1" | ||
|
||
%w{ }.each do |i| | ||
depends i | ||
end | ||
version '0.1.2' |
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
Oops, something went wrong.
This should be Apache shouldn't it?