Skip to content

Commit

Permalink
fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
theyosef committed Apr 22, 2015
1 parent f515503 commit f55b66b
Showing 1 changed file with 18 additions and 16 deletions.
34 changes: 18 additions & 16 deletions manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -24,39 +24,41 @@

$local_package_msi = "${temp_media_dir}${package_name}-${package_version}.msi"

if "${operatingsystem}" == 'windows' {
if "${::operatingsystem}" == 'windows' {

Exec {
path => "${::path}",
}

if $package_ensure == 'installed' or $package_ensure == 'present' {




file {"${config_dir}":
ensure => directory,
}
->

package { $package_name:
ensure => $package_ensure,
source => $local_package_msi,
require => File["${local_package_msi}"],
}
->

file { "${config_dir}${config_file}":
ensure => present,
content => regsubst(template('nxlog/nxlog.conf.erb'), '\n', "\r\n", 'EMG'),
require => Package["${package_name}"],
}
~>

service { $service_name:
ensure => $service_ensure,
require => File["${config_dir}${config_file}"],
}



if ! defined(File[$temp_media_dir]) {
file { $temp_media_dir:
ensure=>directory,
}
}
}




if $package_src_http == undef {
file { "${local_package_msi}" :
Expand All @@ -76,17 +78,17 @@
source => "${staging::path}/nxlog/${package_name}-${package_version}.msi",
replace => false,
require => File[$temp_media_dir],
}
}
}




}
}
} # if $package_ensure == 'installed' or $package_ensure == 'present'
}# if "${::operatingsystem}" == 'windows'
else{
notice("NXLOG: Not supported on non-windows platforms at this time.")
}
}# else of (if "${::operatingsystem}" == 'windows')
}

0 comments on commit f55b66b

Please sign in to comment.