Skip to content
This repository has been archived by the owner on Dec 2, 2020. It is now read-only.

Commit

Permalink
Merge pull request #1 from boxen/switch-to-dev
Browse files Browse the repository at this point in the history
WIP: Switch to dev.elasticsearch
  • Loading branch information
jbarnette committed Jan 21, 2013
2 parents 8401396 + 3fe08ab commit 7eb7b22
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 14 deletions.
8 changes: 4 additions & 4 deletions manifests/config.pp
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,13 @@
file { $configfile:
content => template('elasticsearch/elasticsearch.yml.erb'),
require => File[$configdir],
notify => Service['com.boxen.elasticsearch'],
notify => Service['dev.elasticsearch'],
}

file { '/Library/LaunchDaemons/com.boxen.elasticsearch.plist':
content => template('elasticsearch/com.boxen.elasticsearch.plist.erb'),
file { '/Library/LaunchDaemons/dev.elasticsearch.plist':
content => template('elasticsearch/dev.elasticsearch.plist.erb'),
group => 'wheel',
notify => Service['com.boxen.elasticsearch'],
notify => Service['dev.elasticsearch'],
owner => 'root'
}
}
8 changes: 6 additions & 2 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -9,14 +9,18 @@

package { 'boxen/brews/elasticsearch':
ensure => '0.19.9-boxen1',
notify => Service['com.boxen.elasticsearch']
notify => Service['dev.elasticsearch']
}

service { 'com.boxen.elasticsearch':
service { 'dev.elasticsearch':
ensure => running,
require => Package['boxen/brews/elasticsearch']
}

service { 'com.boxen.elasticsearch': # replaced by dev.elasticsearch
before => Service['dev.elasticsearch'],
enable => false
}

file { "${boxen::config::envdir}/elasticsearch.sh":
content => template('elasticsearch/env.sh.erb'),
Expand Down
8 changes: 4 additions & 4 deletions spec/classes/elasticsearch_config_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -24,15 +24,15 @@
should contain_file("#{configdir}/elasticsearch.yml").with({
:content => File.read('spec/fixtures/elasticsearch.yml'),
:require => "File[#{configdir}]",
:notify => 'Service[com.boxen.elasticsearch]',
:notify => 'Service[dev.elasticsearch]',
})
end

it do
should contain_file('/Library/LaunchDaemons/com.boxen.elasticsearch.plist').with({
:content => File.read('spec/fixtures/com.boxen.elasticsearch.plist'),
should contain_file('/Library/LaunchDaemons/dev.elasticsearch.plist').with({
:content => File.read('spec/fixtures/dev.elasticsearch.plist'),
:group => 'wheel',
:notify => 'Service[com.boxen.elasticsearch]',
:notify => 'Service[dev.elasticsearch]',
:owner => 'root',
})
end
Expand Down
4 changes: 2 additions & 2 deletions spec/classes/elasticsearch_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,12 @@
it do
should contain_package('boxen/brews/elasticsearch').with({
:ensure => '0.19.9-boxen1',
:notify => 'Service[com.boxen.elasticsearch]',
:notify => 'Service[dev.elasticsearch]',
})
end

it do
should contain_service('com.boxen.elasticsearch').with({
should contain_service('dev.elasticsearch').with({
:ensure => 'running',
:require => 'Package[boxen/brews/elasticsearch]',
})
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.boxen.elasticsearch</string>
<string>dev.elasticsearch</string>

<key>Boxen</key>
<dict>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.boxen.elasticsearch</string>
<string>dev.elasticsearch</string>

<key>Boxen</key>
<dict>
Expand Down

0 comments on commit 7eb7b22

Please sign in to comment.