Skip to content

Commit

Permalink
initial
Browse files Browse the repository at this point in the history
  • Loading branch information
Christian Mague committed Feb 7, 2018
1 parent d126f2e commit bba3f25
Show file tree
Hide file tree
Showing 7 changed files with 24 additions and 12 deletions.
6 changes: 3 additions & 3 deletions Gemfile
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
source ENV['GEM_SOURCE'] || 'https://rubygems.org'

puppetversion = ENV.key?('PUPPET_VERSION') ? ENV['PUPPET_VERSION'] : ['>= 3.3']
gem 'facter', '>= 1.7.0'
gem 'metadata-json-lint'
gem 'puppet', puppetversion
gem 'puppetlabs_spec_helper', '>= 1.2.0'
gem 'puppet-lint', '>= 1.0.0'
gem 'facter', '>= 1.7.0'
gem 'puppetlabs_spec_helper', '>= 1.2.0'
gem 'rspec-puppet'

# rspec must be v2 for ruby 1.8.7
if RUBY_VERSION >= '1.8.7' && RUBY_VERSION < '1.9'
gem 'rspec', '~> 2.0'
gem 'rake', '~> 10.0'
gem 'rspec', '~> 2.0'
else
# rubocop requires ruby >= 1.9
gem 'rubocop'
Expand Down
2 changes: 1 addition & 1 deletion Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ end

desc 'Run lint, validate, and spec tests.'
task :test do
[:lint, :validate, :spec].each do |test|
%i[lint validate spec].each do |test|
Rake::Task[test].invoke
end
end
14 changes: 13 additions & 1 deletion manifests/apt_repo.pp
Original file line number Diff line number Diff line change
@@ -1,5 +1,17 @@
# Class: jenkins::apt_repo
# ===========================
class jenkins::apt_repo inherits jenkins {
class jenkins::apt_repo {
if $jenkins::manage_apt_repo {
include ::apt
apt::source { 'jenkins-ci':
location => $jenkins::repo_url,
release => 'binary/',
repos => '',
key => {
id => $jenkins::repo_key_id,
source => $jenkins::repo_key_source,
}
}

}
}
2 changes: 1 addition & 1 deletion manifests/configure.pp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Class: jenkins::configure
# ===========================
class jenkins::configure inherits jenkins {
class jenkins::configure {

}
8 changes: 4 additions & 4 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
String $repo_key_source = 'http://pkg.jenkins-ci.org/debian/jenkins-ci.org.key',
){

include jenkins::apt_repo
include jenkins::install
include jenkins::configure
include jenkins::service
contain jenkins::apt_repo
contain jenkins::install
contain jenkins::configure
contain jenkins::service

Class['::jenkins::apt_repo']
-> Class['::jenkins::install']
Expand Down
2 changes: 1 addition & 1 deletion manifests/install.pp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Class: jenkins::install
# ===========================
class jenkins::install inherits jenkins {
class jenkins::install {

}
2 changes: 1 addition & 1 deletion manifests/service.pp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# Class: jenkins::service
# ===========================
class jenkins::service inherits jenkins {
class jenkins::service {

}

0 comments on commit bba3f25

Please sign in to comment.