Skip to content

Commit

Permalink
#3287: base.dockerfile, update install + r10k syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
jeff1evesque committed Oct 2, 2018
1 parent b463d1c commit 952cae7
Showing 1 changed file with 3 additions and 10 deletions.
13 changes: 3 additions & 10 deletions dockerfile/base.dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ RUN mkdir -p $ROOT_PROJECT/log $ROOT_PUPPET/code/environment/$ENVIRONMENT $ROOT_
## Note: r10k requires 'git' installed
##
RUN apt-get -y update
RUN apt-get -y install wget=1.17.1-1ubuntu*
RUN apt-get -y install wget=1.17* curl=7.47*
RUN wget https://apt.puppetlabs.com/$PUPPET_VERSION
RUN dpkg -i $PUPPET_VERSION
RUN apt-get -y update
Expand All @@ -31,24 +31,17 @@ COPY puppet/environment/$ENVIRONMENT/modules $ROOT_PUPPET/code/modules
COPY hiera $ROOT_PUPPET/puppet/hiera
COPY hiera.yaml $ROOT_PUPPET/puppet

## install ruby
RUN gpg --keyserver hkp://keys.gnupg.net --recv-keys 409B6B1796C275462A1703113804BB82D39DC0E3
RUN cd /tmp && \curl -sSL https://get.rvm.io -o rvm.sh
RUN cat /tmp/rvm.sh | bash -s stable
RUN source /usr/local/rvm/scripts/rvm
RUN rvm list known && rvm install 2.5.1

## install r10k
##
## Note: r10k requires 'semantic_puppet' at '0.1.0':
##
## https://github.com/jeff1evesque/machine-learning/issues/2991
##
RUN apt-get -y install rubygems-integration=1.10
RUN apt-get -y install ruby=1:2.3* rubygems-integration=1.10
RUN gem install semantic_puppet:0.1.0 puppet_forge:2.2.9 r10k:3.0.2

## install puppet modules using puppetfile with r10k
RUN PUPPETFILE=$ENVPATH/Puppetfile PUPPETFILE_DIR=$CONTRIB_MODULES r10k puppetfile install
RUN r10k puppetfile install --puppetfile $ENVPATH/Puppetfile --moduledir $CONTRIB_MODULES

## provision with puppet
RUN $PUPPET apply apply -e 'class { system: }' --modulepath=$CONTRIB_MODULES:$MODULES --confdir=$ROOT_PUPPET/puppet

0 comments on commit 952cae7

Please sign in to comment.