Skip to content

Commit

Permalink
Merge pull request #59 from cappetta/master
Browse files Browse the repository at this point in the history
minor enhancements to bring osx bootstrap up-to-date
  • Loading branch information
grubernaut committed Jun 27, 2017
2 parents d3949b1 + 7d6c14f commit bd43db1
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions mac_os_x.sh
@@ -1,18 +1,20 @@
#!/usr/bin/env bash
#!/usr/bin/env bash
#
# This bootstraps Puppet on Mac OS X 10.8 and 10.7.
# This bootstraps Puppet on Mac OS X 10.9 - 10.12 && is depecrated for 10.7/10.8
#
# Optional environmental variables:
# - FACTER_PACKAGE_URL: The URL to the Facter package to install.
# - PUPPET_PACKAGE_URL: The URL to the Puppet package to install.
#
set -e

OSX_VERSION=$(sw_vers | grep -i productversion| awk '{print $2}' | cut -f1,2 -d'.')

#--------------------------------------------------------------------
# Modifiable variables, please set them via environmental variables.
#--------------------------------------------------------------------
FACTER_PACKAGE_URL=${FACTER_PACKAGE_URL:-"http://downloads.puppetlabs.com/mac/facter-1.7.2.dmg"}
PUPPET_PACKAGE_URL=${PUPPET_PACKAGE_URL:-"http://puppetlabs.com/downloads/mac/puppet-3.2.3.dmg"}
FACTER_PACKAGE_URL=${FACTER_PACKAGE_URL:-"http://downloads.puppetlabs.com/mac/facter-latest.dmg"}
PUPPET_PACKAGE_URL=${PUPPET_PACKAGE_URL:-"http://downloads.puppetlabs.com/mac/$OSX_VERSION/PC1/x86_64/puppet-agent-1.10.4-1.osx$OSX_VERSION.dmg"}

#--------------------------------------------------------------------
# NO TUNABLES BELOW THIS POINT.
Expand Down Expand Up @@ -57,3 +59,5 @@ install_dmg "Facter" "${FACTER_PACKAGE_URL}"

# Hide all users from the loginwindow with uid below 500, which will include the puppet user
defaults write /Library/Preferences/com.apple.loginwindow Hide500Users -bool YES

echo "finished installing puppet..."

0 comments on commit bd43db1

Please sign in to comment.