Revert "Remove r10k env vars with proper args"
It broke all unit tests jobs:
http://logs.openstack.org/98/535698/16/gate/puppet-openstack-unit-4.8-centos-7/bd7dedf/job-output.txt.gz#_2018-02-05_23_19_05_369251
This reverts commit 9f14f75ec6
.
Change-Id: Ibcb2bb60a668d232371e4d87febad6d67b3302d8
This commit is contained in:
parent
932aa7b59e
commit
3c8f4ccd85
16
functions
16
functions
@ -8,22 +8,21 @@
|
||||
#
|
||||
# - ``SCRIPT_DIR`` must be set to script path
|
||||
# - ``GEM_BIN_DIR`` must be set to Gem bin directory
|
||||
# - ``MODULES_DIR`` must be set to Puppet modules directory
|
||||
install_external() {
|
||||
r10k -v DEBUG puppetfile install --puppetfile ${SCRIPT_DIR}/Puppetfile1 --moduledir ${MODULES_DIR}
|
||||
PUPPETFILE=${SCRIPT_DIR}/Puppetfile1 r10k -v DEBUG puppetfile install
|
||||
}
|
||||
|
||||
# Install Puppet OpenStack modules with zuul-cloner
|
||||
# Uses the following variables:
|
||||
#
|
||||
# - ``MODULES_DIR`` must be set to Puppet modules directory
|
||||
# - ``PUPPETFILE_DIR`` must be set to Puppet modules directory
|
||||
# - ``SCRIPT_DIR`` must be set to script path
|
||||
# - ``ZUUL_BRANCH`` must be set to Zuul branch. Fallback to 'master'.
|
||||
install_openstack() {
|
||||
cat > clonemap.yaml <<EOF
|
||||
clonemap:
|
||||
- name: '(.*?)/puppet-(.*)'
|
||||
dest: '$MODULES_DIR/\2'
|
||||
dest: '$PUPPETFILE_DIR/\2'
|
||||
EOF
|
||||
|
||||
# Periodic jobs run without ref on master
|
||||
@ -40,26 +39,25 @@ EOF
|
||||
|
||||
# Because openstack-integration can't be a class name.
|
||||
# https://projects.puppetlabs.com/issues/5268
|
||||
mv $MODULES_DIR/openstack-integration $MODULES_DIR/openstack_integration
|
||||
mv $PUPPETFILE_DIR/openstack-integration $PUPPETFILE_DIR/openstack_integration
|
||||
}
|
||||
|
||||
# Install all Puppet modules with r10k
|
||||
# Uses the following variables:
|
||||
#
|
||||
# - ``SCRIPT_DIR`` must be set to script path
|
||||
# - ``MODULES_DIR`` must be set to Puppet modules directory
|
||||
install_all() {
|
||||
# When installing from local source, we want to install the current source
|
||||
# we're working from.
|
||||
r10k -v DEBUG puppetfile install --puppetfile ${SCRIPT_DIR}/Puppetfile --moduledir ${MODULES_DIR}
|
||||
cp -a ${SCRIPT_DIR} ${MODULES_DIR}/openstack_integration
|
||||
PUPPETFILE=${SCRIPT_DIR}/Puppetfile r10k -v DEBUG puppetfile install
|
||||
cp -a ${SCRIPT_DIR} ${PUPPETFILE_DIR}/openstack_integration
|
||||
}
|
||||
|
||||
# Install Puppet OpenStack modules and dependencies by using
|
||||
# zuul-cloner or r10k.
|
||||
# Uses the following variables:
|
||||
#
|
||||
# - ``MODULES_DIR`` must be set to Puppet modules directory
|
||||
# - ``PUPPETFILE_DIR`` must be set to Puppet modules directory
|
||||
# - ``SCRIPT_DIR`` must be set to script path
|
||||
# - ``ZUUL_BRANCH`` must be set to Zuul branch
|
||||
install_modules() {
|
||||
|
@ -18,7 +18,7 @@ if [ -e /opt/puppetlabs/bin/puppet ]; then
|
||||
fi
|
||||
|
||||
export SCRIPT_DIR=$(cd `dirname $0` && pwd -P)
|
||||
export MODULES_DIR=${MODULES_DIR:-${PUPPET_BASE_PATH}/modules}
|
||||
export PUPPETFILE_DIR=${PUPPETFILE_DIR:-${PUPPET_BASE_PATH}/modules}
|
||||
source $SCRIPT_DIR/functions
|
||||
|
||||
print_header 'Start (install_modules.sh)'
|
||||
@ -31,7 +31,7 @@ gem install puppet_forge -v '= 2.2.6' --verbose
|
||||
gem install r10k --no-ri --no-rdoc --verbose
|
||||
|
||||
# make sure there is no puppet module pre-installed
|
||||
rm -rf "${MODULES_DIR:?}/"*
|
||||
rm -rf "${PUPPETFILE_DIR:?}/"*
|
||||
|
||||
print_header 'Install Modules'
|
||||
install_modules
|
||||
|
@ -18,7 +18,7 @@ else
|
||||
fi
|
||||
|
||||
export SCRIPT_DIR=$(cd `dirname $0` && pwd -P)
|
||||
export MODULES_DIR=${MODULES_DIR:-${PUPPET_BASE_PATH}/modules}
|
||||
export PUPPETFILE_DIR=${PUPPETFILE_DIR:-${PUPPET_BASE_PATH}/modules}
|
||||
source $SCRIPT_DIR/functions
|
||||
|
||||
print_header 'Start (install_modules_unit.sh)'
|
||||
|
Loading…
Reference in New Issue
Block a user