Skip to content

Commit

Permalink
Update to use 3 repos
Browse files Browse the repository at this point in the history
  • Loading branch information
GregSutcliffe authored and Dominic Cleal committed Dec 14, 2012
1 parent 2cafafc commit c7b3916
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 10 deletions.
2 changes: 1 addition & 1 deletion manifests/init.pp
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
$passenger = $foreman::params::passenger,
$ssl = $foreman::params::ssl,
$custom_repo = $foreman::params::custom_repo,
$use_testing = $foreman::params::use_testing,
$repo = $foreman::params::repo,
$use_sqlite = $foreman::params::use_sqlite,
$railspath = $foreman::params::railspath,
$app_root = $foreman::params::app_root,
Expand Down
2 changes: 1 addition & 1 deletion manifests/install.pp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
class foreman::install {
if ! $foreman::custom_repo {
foreman::install::repos { 'foreman':
use_testing => $foreman::use_testing,
repo => $foreman::repo
}
}

Expand Down
8 changes: 2 additions & 6 deletions manifests/install/repos.pp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
define foreman::install::repos(
$use_testing = false
$repo = stable
) {
case $::operatingsystem {
redhat,centos,fedora,Scientific: {
Expand All @@ -21,12 +21,8 @@
}
}
Debian,Ubuntu: {
$component_name = $use_testing ? {
true => 'nightly',
default => 'stable',
}
file { "/etc/apt/sources.list.d/${name}.list":
content => "deb http://deb.theforeman.org/ ${::lsbdistcodename} ${component_name}\n"
content => "deb http://deb.theforeman.org/ ${::lsbdistcodename} ${repo}\n"
}
~>
exec { "foreman-key-${name}":
Expand Down
4 changes: 2 additions & 2 deletions manifests/params.pp
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@
# if set to true, no repo will be added by this module, letting you to
# set it to some custom location.
$custom_repo = false
# allow usage of testing rpm/deb packages as well
$use_testing = false
# this can be stable, rc, or nightly
$repo = 'stable'
$railspath = '/usr/share'
$app_root = "${railspath}/foreman"
$user = 'foreman'
Expand Down

0 comments on commit c7b3916

Please sign in to comment.