mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-15 05:32:49 +01:00
soup salt and repos ohh my
This commit is contained in:
@@ -409,6 +409,30 @@ up_2.3.2X_to_2.3.30() {
|
||||
sed -i "/^strelka:/a \\ repos: \n - https://github.com/Neo23x0/signature-base" /opt/so/saltstack/local/pillar/global.sls;
|
||||
fi
|
||||
check_log_size_limit
|
||||
INSTALLEDVERSION=2.3.30
|
||||
}
|
||||
|
||||
up_2.3.3X_to_2.3.50() {
|
||||
if [[ $OS == 'centos' ]]; then
|
||||
# Import GPG Keys
|
||||
gpg_rpm_import
|
||||
|
||||
if [[ ! $is_airgap ]]; then
|
||||
|
||||
DELREPOS=('CentOS-Base' 'CentOS-CR' 'CentOS-Debuginfo' 'docker-ce' 'CentOS-fasttrack' 'CentOS-Media' 'CentOS-Sources' 'CentOS-Vault' 'CentOS-x86_64-kernel' 'epel' 'epel-testing' 'saltstack' 'wazuh')
|
||||
|
||||
for DELREPO in "${DELREPOS[@]}";
|
||||
rm /etc/yum.repos.d/$DELREPO
|
||||
done
|
||||
|
||||
# Copy the new repo file if not airgap
|
||||
cp $UPDATE_DIR/salt/common/yum_repos/securityonion.repo /etc/yum.repos.d/
|
||||
yum clean all
|
||||
yum repolist
|
||||
fi
|
||||
fi
|
||||
INSTALLEDVERSION=2.3.50
|
||||
|
||||
}
|
||||
|
||||
verify_upgradespace() {
|
||||
@@ -503,7 +527,7 @@ upgrade_salt() {
|
||||
echo "Performing upgrade of Salt from $INSTALLEDSALTVERSION to $NEWSALTVERSION."
|
||||
echo ""
|
||||
# If CentOS
|
||||
if [ "$OS" == "centos" ]; then
|
||||
if [[ $OS == 'centos' ]]; then
|
||||
echo "Removing yum versionlock for Salt."
|
||||
echo ""
|
||||
yum versionlock delete "salt-*"
|
||||
@@ -518,7 +542,7 @@ upgrade_salt() {
|
||||
echo ""
|
||||
yum versionlock add "salt-*"
|
||||
# Else do Ubuntu things
|
||||
elif [ "$OS" == "ubuntu" ]; then
|
||||
elif [[ $OS == 'ubuntu' ]]; then
|
||||
echo "Removing apt hold for Salt."
|
||||
echo ""
|
||||
apt-mark unhold "salt-common"
|
||||
|
||||
Reference in New Issue
Block a user