mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-07 01:32:47 +01:00
Force package installation
This commit is contained in:
@@ -62,8 +62,9 @@ elastic_fleet_package_latest_version_check() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
elastic_fleet_package_install() {
|
elastic_fleet_package_install() {
|
||||||
PKGKEY=$1
|
PKG=$1
|
||||||
curl -s -K /opt/so/conf/elasticsearch/curl.config -b "sid=$SESSIONCOOKIE" -L -X POST -H 'kbn-xsrf: true' "localhost:5601/api/fleet/epm/packages/$PKGKEY"
|
VERSION=$2
|
||||||
|
curl -s -K /opt/so/conf/elasticsearch/curl.config -b "sid=$SESSIONCOOKIE" -L -X POST -H 'kbn-xsrf: true' -H 'Content-Type: application/json' -d '{"force":true}' "localhost:5601/api/fleet/epm/packages/$PKG/$VERSION"
|
||||||
}
|
}
|
||||||
|
|
||||||
elastic_fleet_package_is_installed() {
|
elastic_fleet_package_is_installed() {
|
||||||
|
|||||||
@@ -11,7 +11,7 @@
|
|||||||
{%- for PACKAGE in SUPPORTED_PACKAGES %}
|
{%- for PACKAGE in SUPPORTED_PACKAGES %}
|
||||||
echo "Upgrading {{ PACKAGE }} package..."
|
echo "Upgrading {{ PACKAGE }} package..."
|
||||||
VERSION=$(elastic_fleet_package_latest_version_check "{{ PACKAGE }}")
|
VERSION=$(elastic_fleet_package_latest_version_check "{{ PACKAGE }}")
|
||||||
elastic_fleet_package_install "{{ PACKAGE }}-$VERSION"
|
elastic_fleet_package_install "{{ PACKAGE }}" "$VERSION"
|
||||||
echo
|
echo
|
||||||
{%- endfor %}
|
{%- endfor %}
|
||||||
echo
|
echo
|
||||||
|
|||||||
Reference in New Issue
Block a user