Revision a0c517b5
Added by Vincent MEMBRÉ over 6 years ago
rudder-webapp/SOURCES/rudder-upgrade | ||
---|---|---|
# - All versions : upgrade system Techniques automatically and reload the Technique library
|
||
# - All versions : Check that Rudder database is able to handle backslash
|
||
# - All versions : Check for the PostgreSQL version (>= 8.4)
|
||
# - All, 4.2.0+ : Commit new hooks
|
||
# - 2.10.17 : Migration DB schema to correct the historization of rules
|
||
# - 2.10.17 : Migration DB schema to add historization of global agent schedule
|
||
# - 2.11.19 : Add index on fileformat for eventlog
|
||
... | ... | |
# - 4.1.0 : Add the property to configure relay api location
|
||
# - 4.1.0 : Add property to define hooks ignore suffixes
|
||
# - 4.1.0 : Migrate script properties to hooks
|
||
# - 4.2.0 : Rename hooks to have a better ordering of hooks
|
||
# - 4.2.4, 4.3.0 : Remove 90-reload hook since logic was integrated to Rudder in #11749
|
||
####################################################################################
|
||
|
||
# Some paths
|
||
... | ... | |
done
|
||
cd ${CURRENT}
|
||
|
||
# 4.2.4, 4.3.0: Remove 90-reload hook since logic was integrated to Rudder in #11749
|
||
CURRENT="$(pwd)"
|
||
cd ${CONFIGURATION_REPOSITORY}/ncf
|
||
for hook_file in 90_reload.sh; do
|
||
hook=ncf-hooks.d/post.write_technique.${hook_file}
|
||
if [ -f ${hook} ]; then
|
||
git ls-files --error-unmatch ${hook} >/dev/null 2>&1
|
||
MANAGED_BY_GIT=$?
|
||
if [ ${MANAGED_BY_GIT} -eq 0 ]; then
|
||
git rm ${hook}
|
||
git commit -m "Remove technique editor hook \"${hook}\""
|
||
else
|
||
rm ${hook}
|
||
fi
|
||
fi
|
||
done
|
||
cd ${CURRENT}
|
||
|
||
|
||
# all, started from 4.2.0: Commit new hooks
|
||
CURRENT="$(pwd)"
|
||
cd ${CONFIGURATION_REPOSITORY}/ncf
|
||
for hook_file in 10_commit.sh 50_rudderify.sh 90_reload.sh; do
|
||
for hook_file in 10_commit.sh 50_rudderify.sh; do
|
||
hook=ncf-hooks.d/post.write_technique.${hook_file}
|
||
if [ -f ${hook} ]; then
|
||
git add ${hook}
|
rudder-webapp/SPECS/rudder-webapp.spec | ||
---|---|---|
Source26: rudder-apache-webapp-ssl.conf
|
||
Source27: rudder-apache-webapp-nossl.conf
|
||
Source28: rudder-webapp.fc
|
||
Source29: post.write_technique.90_reload.sh
|
||
|
||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||
BuildArch: noarch
|
||
... | ... | |
|
||
install -m 755 %{SOURCE15} %{buildroot}%{ruddervardir}/configuration-repository/ncf/ncf-hooks.d/
|
||
install -m 755 %{SOURCE16} %{buildroot}%{ruddervardir}/configuration-repository/ncf/ncf-hooks.d/
|
||
install -m 755 %{SOURCE29} %{buildroot}%{ruddervardir}/configuration-repository/ncf/ncf-hooks.d/
|
||
|
||
# Add rudder-metrics-reporting
|
||
cp %{SOURCE17} %{buildroot}%{rudderdir}/bin/
|
rudder-webapp/debian/rules | ||
---|---|---|
dh_install --SOURCEDIR=$(CURDIR)/SOURCES/ rudder-web /opt/rudder/etc/server-roles.d/
|
||
dh_install --SOURCEDIR=$(CURDIR)/SOURCES/ post.write_technique.10_commit.sh /var/rudder/configuration-repository/ncf/ncf-hooks.d/
|
||
dh_install --SOURCEDIR=$(CURDIR)/SOURCES/ post.write_technique.50_rudderify.sh /var/rudder/configuration-repository/ncf/ncf-hooks.d/
|
||
dh_install --SOURCEDIR=$(CURDIR)/SOURCES/ post.write_technique.90_reload.sh /var/rudder/configuration-repository/ncf/ncf-hooks.d/
|
||
|
||
# Install upgrade tools and migration scripts
|
||
|
Also available in: Unified diff
Fixes #12010: Remove reload.sh hooks since it will be done by Rudder