-
Notifications
You must be signed in to change notification settings - Fork 20
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #11 from terrimonster/test_38
Changes for PE 3.8
- Loading branch information
Showing
11 changed files
with
67 additions
and
92 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 |
---|---|---|
@@ -1,32 +1,18 @@ | ||
#!/bin/bash | ||
|
||
rm -rf /etc/puppetlabs/puppet/environments/production | ||
HOSTNAME=`hostname` | ||
|
||
if [[ $HOSTNAME =~ vagrant ]]; then | ||
MODPATH='/vagrant/site' | ||
else | ||
MODPATH='/etc/puppetlabs/puppet/environments/production/site' | ||
fi | ||
|
||
/opt/puppet/bin/puppet module install zack-r10k --modulepath \ | ||
/etc/puppetlabs/puppet/modules --ignore-requirements | ||
/opt/puppet/bin/puppet apply -e 'include profile::puppet::r10k' --modulepath=$MODPATH | ||
|
||
cat > /tmp/newsite.pp <<EOM | ||
case $::settings::server { | ||
'xmaster.vagrant.vm': { | ||
\$remote = '/vagrant' | ||
} | ||
default: { | ||
\$remote = '[email protected]:terrimonster/puppet-control.git' | ||
} | ||
} | ||
class { 'r10k': | ||
version => '1.4.1', | ||
remote => \$remote, | ||
} | ||
EOM | ||
echo "APPLYING R10K" | ||
/opt/puppet/bin/puppet apply /tmp/newsite.pp \ | ||
--modulepath=/etc/puppetlabs/puppet/modules | ||
rm -rf /etc/puppetlabs/puppet/environments/production | ||
|
||
/opt/puppet/bin/r10k deploy environment -p production --puppetfile \ | ||
--verbose debug | ||
echo "Sleeping for 10 seconds while prod env is recognized" | ||
|
||
sleep 10 | ||
|
||
/opt/puppet/bin/puppet agent -t |
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 was deleted.
Oops, something went wrong.
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
class profile::puppet::r10k ( | ||
$remote = $::profile::puppet::params::remote, | ||
$environmentpath = $::profile::puppet::params::environmentpath, | ||
) inherits ::profile::puppet::params { | ||
file { 'r10k_config': | ||
ensure => file, | ||
owner => 'root', | ||
group => 'root', | ||
path => '/etc/puppetlabs/r10k/r10k.yaml', | ||
content => template('profile/r10k.yaml.erb'), | ||
} | ||
} |
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,4 @@ | ||
sources: | ||
mysource: | ||
remote: <%= @remote %> | ||
basedir: <%= @environmentpath %> |
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,4 @@ | ||
class role::puppet::master { | ||
include profile::base | ||
include profile::base::linux | ||
include profile::puppet::master | ||
} |
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