Skip to content
Snippets Groups Projects
Commit 42d6dd61 authored by alcalina's avatar alcalina
Browse files

Deploy role::onlyoffice using Libvirt

parent 03d50f8d
No related branches found
No related tags found
No related merge requests found
Pipeline #51820 failed
stages:
- check-code
- compile
- deploy
check-code:
image: ninfra/puppet-checker:0.0.1
......@@ -29,3 +30,12 @@ compile-profiles:
done < <( find ./profile/manifests/ -name "*.pp" -a -exec grep ^class "{}" \; | awk "{ print \$2 }" );'
tags:
- docker
deploy-role-onlyoffice:
stage: deploy
variables:
GIT_SUBMODULE_STRATEGY: recursive
script:
- sudo ./.scripts/deploy-puppet-master.sh role::onlyoffice
tags:
- libvirt
#!/bin/bash
#
# Deploy a role using Puppet Apply.
set -x
CLASS=${1}
if [ -z "${CLASS}" ]; then
echo "Usage: ${0} class"
exit 1
fi
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"
REPO_DIR="$( dirname ${SCRIPT_DIR} )"
apt update
apt install -qy puppet
git -C ${REPO_DIR} submodule update --init
# deploy a role
puppet apply \
--detailed-exitcodes \
--modulepath ${REPO_DIR}/modules \
--hiera-config ${REPO_DIR}/hiera.yaml \
--codedir ${REPO_DIR} \
-e "include ${CLASS}"
test "${?}" = 2 || exit 1 # Puppet exit code 2: The run succeeded, and some resources were changed.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment