mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 09:12:45 +01:00
minio and change to global
This commit is contained in:
@@ -1,11 +1,11 @@
|
|||||||
{%- set FLEETMANAGER = salt['pillar.get']('static:fleet_manager', False) -%}
|
{%- set FLEETMANAGER = salt['pillar.get']('global:fleet_manager', False) -%}
|
||||||
{%- set FLEETNODE = salt['pillar.get']('static:fleet_node', False) -%}
|
{%- set FLEETNODE = salt['pillar.get']('global:fleet_node', False) -%}
|
||||||
{% set WAZUH = salt['pillar.get']('manager:wazuh', '0') %}
|
{% set WAZUH = salt['pillar.get']('manager:wazuh', '0') %}
|
||||||
{% set THEHIVE = salt['pillar.get']('manager:thehive', '0') %}
|
{% set THEHIVE = salt['pillar.get']('manager:thehive', '0') %}
|
||||||
{% set PLAYBOOK = salt['pillar.get']('manager:playbook', '0') %}
|
{% set PLAYBOOK = salt['pillar.get']('manager:playbook', '0') %}
|
||||||
{% set FREQSERVER = salt['pillar.get']('manager:freq', '0') %}
|
{% set FREQSERVER = salt['pillar.get']('manager:freq', '0') %}
|
||||||
{% set DOMAINSTATS = salt['pillar.get']('manager:domainstats', '0') %}
|
{% set DOMAINSTATS = salt['pillar.get']('manager:domainstats', '0') %}
|
||||||
{% set ZEEKVER = salt['pillar.get']('static:zeekversion', 'COMMUNITY') %}
|
{% set ZEEKVER = salt['pillar.get']('global:zeekversion', 'COMMUNITY') %}
|
||||||
{% set GRAFANA = salt['pillar.get']('manager:grafana', '0') %}
|
{% set GRAFANA = salt['pillar.get']('manager:grafana', '0') %}
|
||||||
|
|
||||||
eval:
|
eval:
|
||||||
|
|||||||
@@ -4,4 +4,4 @@ logstash:
|
|||||||
config:
|
config:
|
||||||
- so/0009_input_beats.conf
|
- so/0009_input_beats.conf
|
||||||
- so/0010_input_hhbeats.conf
|
- so/0010_input_hhbeats.conf
|
||||||
- so/9999_output_redis.conf.jinja
|
- so/9998_output_minio.conf.jinja
|
||||||
|
|||||||
@@ -2,7 +2,7 @@ logstash:
|
|||||||
pipelines:
|
pipelines:
|
||||||
search:
|
search:
|
||||||
config:
|
config:
|
||||||
- so/0900_input_redis.conf.jinja
|
- so/0899_input_minio.conf.jinja
|
||||||
- so/9000_output_zeek.conf.jinja
|
- so/9000_output_zeek.conf.jinja
|
||||||
- so/9002_output_import.conf.jinja
|
- so/9002_output_import.conf.jinja
|
||||||
- so/9034_output_syslog.conf.jinja
|
- so/9034_output_syslog.conf.jinja
|
||||||
|
|||||||
@@ -14,14 +14,14 @@ base:
|
|||||||
- elasticsearch.search
|
- elasticsearch.search
|
||||||
|
|
||||||
'*_sensor':
|
'*_sensor':
|
||||||
- static
|
- global
|
||||||
- zeeklogs
|
- zeeklogs
|
||||||
- healthcheck.sensor
|
- healthcheck.sensor
|
||||||
- minions.{{ grains.id }}
|
- minions.{{ grains.id }}
|
||||||
|
|
||||||
'*_manager or *_managersearch':
|
'*_manager or *_managersearch':
|
||||||
- match: compound
|
- match: compound
|
||||||
- static
|
- global
|
||||||
- data.*
|
- data.*
|
||||||
- secrets
|
- secrets
|
||||||
- minions.{{ grains.id }}
|
- minions.{{ grains.id }}
|
||||||
@@ -36,7 +36,7 @@ base:
|
|||||||
- secrets
|
- secrets
|
||||||
- healthcheck.eval
|
- healthcheck.eval
|
||||||
- elasticsearch.eval
|
- elasticsearch.eval
|
||||||
- static
|
- global
|
||||||
- minions.{{ grains.id }}
|
- minions.{{ grains.id }}
|
||||||
|
|
||||||
'*_standalone':
|
'*_standalone':
|
||||||
@@ -48,20 +48,20 @@ base:
|
|||||||
- zeeklogs
|
- zeeklogs
|
||||||
- secrets
|
- secrets
|
||||||
- healthcheck.standalone
|
- healthcheck.standalone
|
||||||
- static
|
- global
|
||||||
- minions.{{ grains.id }}
|
- minions.{{ grains.id }}
|
||||||
|
|
||||||
'*_node':
|
'*_node':
|
||||||
- static
|
- global
|
||||||
- minions.{{ grains.id }}
|
- minions.{{ grains.id }}
|
||||||
|
|
||||||
'*_heavynode':
|
'*_heavynode':
|
||||||
- static
|
- global
|
||||||
- zeeklogs
|
- zeeklogs
|
||||||
- minions.{{ grains.id }}
|
- minions.{{ grains.id }}
|
||||||
|
|
||||||
'*_helix':
|
'*_helix':
|
||||||
- static
|
- global
|
||||||
- fireeye
|
- fireeye
|
||||||
- zeeklogs
|
- zeeklogs
|
||||||
- logstash
|
- logstash
|
||||||
@@ -69,13 +69,13 @@ base:
|
|||||||
- minions.{{ grains.id }}
|
- minions.{{ grains.id }}
|
||||||
|
|
||||||
'*_fleet':
|
'*_fleet':
|
||||||
- static
|
- global
|
||||||
- data.*
|
- data.*
|
||||||
- secrets
|
- secrets
|
||||||
- minions.{{ grains.id }}
|
- minions.{{ grains.id }}
|
||||||
|
|
||||||
'*_searchnode':
|
'*_searchnode':
|
||||||
- static
|
- global
|
||||||
- logstash
|
- logstash
|
||||||
- logstash.search
|
- logstash.search
|
||||||
- elasticsearch.search
|
- elasticsearch.search
|
||||||
|
|||||||
@@ -20,7 +20,7 @@
|
|||||||
|
|
||||||
{% if role in ['eval', 'managersearch', 'manager', 'standalone'] %}
|
{% if role in ['eval', 'managersearch', 'manager', 'standalone'] %}
|
||||||
{{ append_containers('manager', 'grafana', 0) }}
|
{{ append_containers('manager', 'grafana', 0) }}
|
||||||
{{ append_containers('static', 'fleet_manager', 0) }}
|
{{ append_containers('global', 'fleet_manager', 0) }}
|
||||||
{{ append_containers('manager', 'wazuh', 0) }}
|
{{ append_containers('manager', 'wazuh', 0) }}
|
||||||
{{ append_containers('manager', 'thehive', 0) }}
|
{{ append_containers('manager', 'thehive', 0) }}
|
||||||
{{ append_containers('manager', 'playbook', 0) }}
|
{{ append_containers('manager', 'playbook', 0) }}
|
||||||
@@ -29,11 +29,11 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if role in ['eval', 'heavynode', 'sensor', 'standalone'] %}
|
{% if role in ['eval', 'heavynode', 'sensor', 'standalone'] %}
|
||||||
{{ append_containers('static', 'strelka', 0) }}
|
{{ append_containers('global', 'strelka', 0) }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if role in ['heavynode', 'standalone'] %}
|
{% if role in ['heavynode', 'standalone'] %}
|
||||||
{{ append_containers('static', 'zeekversion', 'SURICATA') }}
|
{{ append_containers('global', 'zeekversion', 'SURICATA') }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if role == 'searchnode' %}
|
{% if role == 'searchnode' %}
|
||||||
@@ -41,5 +41,5 @@
|
|||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
{% if role == 'sensor' %}
|
{% if role == 'sensor' %}
|
||||||
{{ append_containers('static', 'zeekversion', 'SURICATA') }}
|
{{ append_containers('global', 'zeekversion', 'SURICATA') }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
@@ -14,7 +14,7 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{%- set MANAGERIP = salt['pillar.get']('static:managerip', '') -%}
|
{%- set MANAGERIP = salt['pillar.get']('global:managerip', '') -%}
|
||||||
. /usr/sbin/so-common
|
. /usr/sbin/so-common
|
||||||
|
|
||||||
SKIP=0
|
SKIP=0
|
||||||
|
|||||||
@@ -29,9 +29,9 @@ manager_check() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
manager_check
|
manager_check
|
||||||
VERSION=$(grep soversion $local_salt_dir/pillar/static.sls | cut -d':' -f2|sed 's/ //g')
|
VERSION=$(grep soversion $local_salt_dir/pillar/global.sls | cut -d':' -f2|sed 's/ //g')
|
||||||
# Modify static.sls to enable Features
|
# Modify global.sls to enable Features
|
||||||
sed -i 's/features: False/features: True/' $local_salt_dir/pillar/static.sls
|
sed -i 's/features: False/features: True/' $local_salt_dir/pillar/global.sls
|
||||||
SUFFIX="-features"
|
SUFFIX="-features"
|
||||||
TRUSTED_CONTAINERS=( \
|
TRUSTED_CONTAINERS=( \
|
||||||
"so-elasticsearch:$VERSION$SUFFIX" \
|
"so-elasticsearch:$VERSION$SUFFIX" \
|
||||||
|
|||||||
@@ -16,9 +16,9 @@
|
|||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion') %}
|
{% set VERSION = salt['pillar.get']('global:soversion') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{%- set MANAGERIP = salt['pillar.get']('static:managerip') -%}
|
{%- set MANAGERIP = salt['pillar.get']('global:managerip') -%}
|
||||||
|
|
||||||
. /usr/sbin/so-common
|
. /usr/sbin/so-common
|
||||||
|
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
#
|
#
|
||||||
# {%- set FLEET_MANAGER = salt['pillar.get']('static:fleet_manager', False) -%}
|
# {%- set FLEET_MANAGER = salt['pillar.get']('global:fleet_manager', False) -%}
|
||||||
# {%- set FLEET_NODE = salt['pillar.get']('static:fleet_node', False) -%}
|
# {%- set FLEET_NODE = salt['pillar.get']('global:fleet_node', False) -%}
|
||||||
# {%- set FLEET_IP = salt['pillar.get']('static:fleet_ip', '') %}
|
# {%- set FLEET_IP = salt['pillar.get']('global:fleet_ip', '') %}
|
||||||
# {%- set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
# {%- set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
||||||
#
|
#
|
||||||
# Copyright 2014,2015,2016,2017,2018,2019,2020 Security Onion Solutions, LLC
|
# Copyright 2014,2015,2016,2017,2018,2019,2020 Security Onion Solutions, LLC
|
||||||
|
|||||||
@@ -159,7 +159,7 @@ update_version() {
|
|||||||
# Update the version to the latest
|
# Update the version to the latest
|
||||||
echo "Updating the Security Onion version file."
|
echo "Updating the Security Onion version file."
|
||||||
echo $NEWVERSION > /etc/soversion
|
echo $NEWVERSION > /etc/soversion
|
||||||
sed -i "s/$INSTALLEDVERSION/$NEWVERSION/g" /opt/so/saltstack/local/pillar/static.sls
|
sed -i "s/$INSTALLEDVERSION/$NEWVERSION/g" /opt/so/saltstack/local/pillar/global.sls
|
||||||
}
|
}
|
||||||
|
|
||||||
upgrade_check() {
|
upgrade_check() {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% if grains['role'] in ['so-eval', 'so-node', 'so-managersearch', 'so-heavynode', 'so-standalone'] %}
|
{% if grains['role'] in ['so-eval', 'so-node', 'so-managersearch', 'so-heavynode', 'so-standalone'] %}
|
||||||
# Curator
|
# Curator
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{%- set FLEETSETUP = salt['pillar.get']('static:fleetsetup', '0') -%}
|
{%- set FLEETSETUP = salt['pillar.get']('global:fleetsetup', '0') -%}
|
||||||
|
|
||||||
{%- if FLEETSETUP != 0 %}
|
{%- if FLEETSETUP != 0 %}
|
||||||
launcherpkg:
|
launcherpkg:
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
|
|
||||||
# Create the group
|
# Create the group
|
||||||
dstatsgroup:
|
dstatsgroup:
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% set es = salt['pillar.get']('static:managerip', '') %}
|
{% set es = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set hivehost = salt['pillar.get']('static:managerip', '') %}
|
{% set hivehost = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set hivekey = salt['pillar.get']('static:hivekey', '') %}
|
{% set hivekey = salt['pillar.get']('global:hivekey', '') %}
|
||||||
{% set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
{% set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
||||||
|
|
||||||
# Elastalert rule to forward Suricata alerts from Security Onion to a specified TheHive instance.
|
# Elastalert rule to forward Suricata alerts from Security Onion to a specified TheHive instance.
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% set es = salt['pillar.get']('static:managerip', '') %}
|
{% set es = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set hivehost = salt['pillar.get']('static:managerip', '') %}
|
{% set hivehost = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set hivekey = salt['pillar.get']('static:hivekey', '') %}
|
{% set hivekey = salt['pillar.get']('global:hivekey', '') %}
|
||||||
{% set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
{% set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
||||||
|
|
||||||
# Elastalert rule to forward high level Wazuh alerts from Security Onion to a specified TheHive instance.
|
# Elastalert rule to forward high level Wazuh alerts from Security Onion to a specified TheHive instance.
|
||||||
|
|||||||
@@ -12,8 +12,8 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
|
|
||||||
{% if grains['role'] in ['so-eval','so-managersearch', 'so-manager', 'so-standalone'] %}
|
{% if grains['role'] in ['so-eval','so-managersearch', 'so-manager', 'so-standalone'] %}
|
||||||
|
|||||||
@@ -12,8 +12,8 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set FEATURES = salt['pillar.get']('elastic:features', False) %}
|
{% set FEATURES = salt['pillar.get']('elastic:features', False) %}
|
||||||
|
|
||||||
|
|||||||
@@ -6,11 +6,11 @@
|
|||||||
|
|
||||||
|
|
||||||
{%- set HOSTNAME = salt['grains.get']('host', '') %}
|
{%- set HOSTNAME = salt['grains.get']('host', '') %}
|
||||||
{%- set ZEEKVER = salt['pillar.get']('static:zeekversion', 'COMMUNITY') %}
|
{%- set ZEEKVER = salt['pillar.get']('global:zeekversion', 'COMMUNITY') %}
|
||||||
{%- set WAZUHENABLED = salt['pillar.get']('static:wazuh', '0') %}
|
{%- set WAZUHENABLED = salt['pillar.get']('global:wazuh', '0') %}
|
||||||
{%- set STRELKAENABLED = salt['pillar.get']('strelka:enabled', '0') %}
|
{%- set STRELKAENABLED = salt['pillar.get']('strelka:enabled', '0') %}
|
||||||
{%- set FLEETMANAGER = salt['pillar.get']('static:fleet_manager', False) -%}
|
{%- set FLEETMANAGER = salt['pillar.get']('global:fleet_manager', False) -%}
|
||||||
{%- set FLEETNODE = salt['pillar.get']('static:fleet_node', False) -%}
|
{%- set FLEETNODE = salt['pillar.get']('global:fleet_node', False) -%}
|
||||||
|
|
||||||
name: {{ HOSTNAME }}
|
name: {{ HOSTNAME }}
|
||||||
|
|
||||||
|
|||||||
@@ -11,10 +11,10 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set MANAGERIP = salt['pillar.get']('static:managerip', '') %}
|
{% set MANAGERIP = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set FEATURES = salt['pillar.get']('elastic:features', False) %}
|
{% set FEATURES = salt['pillar.get']('elastic:features', False) %}
|
||||||
{% if FEATURES %}
|
{% if FEATURES %}
|
||||||
{% set FEATURES = "-features" %}
|
{% set FEATURES = "-features" %}
|
||||||
|
|||||||
@@ -15,6 +15,7 @@ role:
|
|||||||
- {{ portgroups.mysql }}
|
- {{ portgroups.mysql }}
|
||||||
- {{ portgroups.kibana }}
|
- {{ portgroups.kibana }}
|
||||||
- {{ portgroups.redis }}
|
- {{ portgroups.redis }}
|
||||||
|
- {{ portgroups.minio }}
|
||||||
- {{ portgroups.influxdb }}
|
- {{ portgroups.influxdb }}
|
||||||
- {{ portgroups.fleet_api }}
|
- {{ portgroups.fleet_api }}
|
||||||
- {{ portgroups.cortex }}
|
- {{ portgroups.cortex }}
|
||||||
@@ -38,6 +39,7 @@ role:
|
|||||||
search_node:
|
search_node:
|
||||||
portgroups:
|
portgroups:
|
||||||
- {{ portgroups.redis }}
|
- {{ portgroups.redis }}
|
||||||
|
- {{ portgroups.minio }}
|
||||||
- {{ portgroups.elasticsearch_node }}
|
- {{ portgroups.elasticsearch_node }}
|
||||||
self:
|
self:
|
||||||
portgroups:
|
portgroups:
|
||||||
@@ -99,6 +101,7 @@ role:
|
|||||||
- {{ portgroups.mysql }}
|
- {{ portgroups.mysql }}
|
||||||
- {{ portgroups.kibana }}
|
- {{ portgroups.kibana }}
|
||||||
- {{ portgroups.redis }}
|
- {{ portgroups.redis }}
|
||||||
|
- {{ portgroups.minio }}
|
||||||
- {{ portgroups.influxdb }}
|
- {{ portgroups.influxdb }}
|
||||||
- {{ portgroups.fleet_api }}
|
- {{ portgroups.fleet_api }}
|
||||||
- {{ portgroups.cortex }}
|
- {{ portgroups.cortex }}
|
||||||
@@ -122,6 +125,7 @@ role:
|
|||||||
search_node:
|
search_node:
|
||||||
portgroups:
|
portgroups:
|
||||||
- {{ portgroups.redis }}
|
- {{ portgroups.redis }}
|
||||||
|
- {{ portgroups.minio }}
|
||||||
- {{ portgroups.elasticsearch_node }}
|
- {{ portgroups.elasticsearch_node }}
|
||||||
self:
|
self:
|
||||||
portgroups:
|
portgroups:
|
||||||
@@ -180,6 +184,7 @@ role:
|
|||||||
- {{ portgroups.mysql }}
|
- {{ portgroups.mysql }}
|
||||||
- {{ portgroups.kibana }}
|
- {{ portgroups.kibana }}
|
||||||
- {{ portgroups.redis }}
|
- {{ portgroups.redis }}
|
||||||
|
- {{ portgroups.minio }}
|
||||||
- {{ portgroups.influxdb }}
|
- {{ portgroups.influxdb }}
|
||||||
- {{ portgroups.fleet_api }}
|
- {{ portgroups.fleet_api }}
|
||||||
- {{ portgroups.cortex }}
|
- {{ portgroups.cortex }}
|
||||||
@@ -203,6 +208,7 @@ role:
|
|||||||
search_node:
|
search_node:
|
||||||
portgroups:
|
portgroups:
|
||||||
- {{ portgroups.redis }}
|
- {{ portgroups.redis }}
|
||||||
|
- {{ portgroups.minio }}
|
||||||
- {{ portgroups.elasticsearch_node }}
|
- {{ portgroups.elasticsearch_node }}
|
||||||
self:
|
self:
|
||||||
portgroups:
|
portgroups:
|
||||||
@@ -261,6 +267,7 @@ role:
|
|||||||
- {{ portgroups.mysql }}
|
- {{ portgroups.mysql }}
|
||||||
- {{ portgroups.kibana }}
|
- {{ portgroups.kibana }}
|
||||||
- {{ portgroups.redis }}
|
- {{ portgroups.redis }}
|
||||||
|
- {{ portgroups.minio }}
|
||||||
- {{ portgroups.influxdb }}
|
- {{ portgroups.influxdb }}
|
||||||
- {{ portgroups.fleet_api }}
|
- {{ portgroups.fleet_api }}
|
||||||
- {{ portgroups.cortex }}
|
- {{ portgroups.cortex }}
|
||||||
@@ -284,6 +291,7 @@ role:
|
|||||||
search_node:
|
search_node:
|
||||||
portgroups:
|
portgroups:
|
||||||
- {{ portgroups.redis }}
|
- {{ portgroups.redis }}
|
||||||
|
- {{ portgroups.minio }}
|
||||||
- {{ portgroups.elasticsearch_node }}
|
- {{ portgroups.elasticsearch_node }}
|
||||||
self:
|
self:
|
||||||
portgroups:
|
portgroups:
|
||||||
|
|||||||
@@ -45,6 +45,9 @@ firewall:
|
|||||||
kibana:
|
kibana:
|
||||||
tcp:
|
tcp:
|
||||||
- 5601
|
- 5601
|
||||||
|
minio:
|
||||||
|
tcp:
|
||||||
|
- 9595
|
||||||
mysql:
|
mysql:
|
||||||
tcp:
|
tcp:
|
||||||
- 3306
|
- 3306
|
||||||
|
|||||||
@@ -1,10 +1,10 @@
|
|||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set ENROLLSECRET = salt['pillar.get']('secrets:fleet_enroll-secret') %}
|
{% set ENROLLSECRET = salt['pillar.get']('secrets:fleet_enroll-secret') %}
|
||||||
{% set CURRENTPACKAGEVERSION = salt['pillar.get']('static:fleet_packages-version') %}
|
{% set CURRENTPACKAGEVERSION = salt['pillar.get']('global:fleet_packages-version') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion') %}
|
{% set VERSION = salt['pillar.get']('global:soversion') %}
|
||||||
{% set CUSTOM_FLEET_HOSTNAME = salt['pillar.get']('static:fleet_custom_hostname', None) %}
|
{% set CUSTOM_FLEET_HOSTNAME = salt['pillar.get']('global:fleet_custom_hostname', None) %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{%- set FLEETNODE = salt['pillar.get']('static:fleet_node') -%}
|
{%- set FLEETNODE = salt['pillar.get']('global:fleet_node') -%}
|
||||||
|
|
||||||
{% if CUSTOM_FLEET_HOSTNAME != None and CUSTOM_FLEET_HOSTNAME != '' %}
|
{% if CUSTOM_FLEET_HOSTNAME != None and CUSTOM_FLEET_HOSTNAME != '' %}
|
||||||
{% set HOSTNAME = CUSTOM_FLEET_HOSTNAME %}
|
{% set HOSTNAME = CUSTOM_FLEET_HOSTNAME %}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{% set CUSTOM_FLEET_HOSTNAME = salt['pillar.get']('static:fleet_custom_hostname', None) %}
|
{% set CUSTOM_FLEET_HOSTNAME = salt['pillar.get']('global:fleet_custom_hostname', None) %}
|
||||||
|
|
||||||
so/fleet:
|
so/fleet:
|
||||||
event.send:
|
event.send:
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
{%- set MYSQLPASS = salt['pillar.get']('secrets:mysql', None) -%}
|
{%- set MYSQLPASS = salt['pillar.get']('secrets:mysql', None) -%}
|
||||||
{%- set FLEETPASS = salt['pillar.get']('secrets:fleet', None) -%}
|
{%- set FLEETPASS = salt['pillar.get']('secrets:fleet', None) -%}
|
||||||
{%- set FLEETJWT = salt['pillar.get']('secrets:fleet_jwt', None) -%}
|
{%- set FLEETJWT = salt['pillar.get']('secrets:fleet_jwt', None) -%}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set FLEETARCH = salt['grains.get']('role') %}
|
{% set FLEETARCH = salt['grains.get']('role') %}
|
||||||
|
|
||||||
@@ -10,7 +10,7 @@
|
|||||||
{% set MAININT = salt['pillar.get']('host:mainint') %}
|
{% set MAININT = salt['pillar.get']('host:mainint') %}
|
||||||
{% set MAINIP = salt['grains.get']('ip_interfaces').get(MAININT)[0] %}
|
{% set MAINIP = salt['grains.get']('ip_interfaces').get(MAININT)[0] %}
|
||||||
{% else %}
|
{% else %}
|
||||||
{% set MAINIP = salt['pillar.get']('static:managerip') %}
|
{% set MAINIP = salt['pillar.get']('global:managerip') %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
include:
|
include:
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
{%- set FLEETMANAGER = salt['pillar.get']('static:fleet_manager', False) -%}
|
{%- set FLEETMANAGER = salt['pillar.get']('global:fleet_manager', False) -%}
|
||||||
{%- set FLEETNODE = salt['pillar.get']('static:fleet_node', False) -%}
|
{%- set FLEETNODE = salt['pillar.get']('global:fleet_node', False) -%}
|
||||||
{%- set FLEETHOSTNAME = salt['pillar.get']('static:fleet_hostname', False) -%}
|
{%- set FLEETHOSTNAME = salt['pillar.get']('global:fleet_hostname', False) -%}
|
||||||
{%- set FLEETIP = salt['pillar.get']('static:fleet_ip', False) -%}
|
{%- set FLEETIP = salt['pillar.get']('global:fleet_ip', False) -%}
|
||||||
{% set CUSTOM_FLEET_HOSTNAME = salt['pillar.get']('static:fleet_custom_hostname', None) %}
|
{% set CUSTOM_FLEET_HOSTNAME = salt['pillar.get']('global:fleet_custom_hostname', None) %}
|
||||||
|
|
||||||
{% if CUSTOM_FLEET_HOSTNAME != (None and '') %}
|
{% if CUSTOM_FLEET_HOSTNAME != (None and '') %}
|
||||||
|
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
|
|
||||||
# Create the user
|
# Create the user
|
||||||
fservergroup:
|
fservergroup:
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{%- set MANAGER = salt['pillar.get']('static:managerip', '') %}
|
{%- set MANAGER = salt['pillar.get']('global:managerip', '') %}
|
||||||
apiVersion: 1
|
apiVersion: 1
|
||||||
|
|
||||||
deleteDatasources:
|
deleteDatasources:
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{% set GRAFANA = salt['pillar.get']('manager:grafana', '0') %}
|
{% set GRAFANA = salt['pillar.get']('manager:grafana', '0') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
|
|
||||||
{% if grains['role'] in ['so-manager', 'so-managersearch', 'so-eval', 'so-standalone'] and GRAFANA == 1 %}
|
{% if grains['role'] in ['so-manager', 'so-managersearch', 'so-eval', 'so-standalone'] and GRAFANA == 1 %}
|
||||||
|
|
||||||
|
|||||||
@@ -12,8 +12,8 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
# IDSTools Setup
|
# IDSTools Setup
|
||||||
idstoolsdir:
|
idstoolsdir:
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{% set GRAFANA = salt['pillar.get']('manager:grafana', '0') %}
|
{% set GRAFANA = salt['pillar.get']('manager:grafana', '0') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
|
|
||||||
{% if grains['role'] in ['so-manager', 'so-managersearch', 'so-eval', 'so-standalone'] and GRAFANA == 1 %}
|
{% if grains['role'] in ['so-manager', 'so-managersearch', 'so-eval', 'so-standalone'] and GRAFANA == 1 %}
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# {%- set FLEET_MANAGER = salt['pillar.get']('static:fleet_manager', False) -%}
|
# {%- set FLEET_MANAGER = salt['pillar.get']('global:fleet_manager', False) -%}
|
||||||
# {%- set FLEET_NODE = salt['pillar.get']('static:fleet_node', False) -%}
|
# {%- set FLEET_NODE = salt['pillar.get']('global:fleet_node', False) -%}
|
||||||
# {%- set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
# {%- set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
||||||
|
|
||||||
KIBANA_VERSION="7.6.1"
|
KIBANA_VERSION="7.6.1"
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set FEATURES = salt['pillar.get']('elastic:features', False) %}
|
{% set FEATURES = salt['pillar.get']('elastic:features', False) %}
|
||||||
{% if FEATURES %}
|
{% if FEATURES %}
|
||||||
|
|||||||
@@ -12,8 +12,8 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set FEATURES = salt['pillar.get']('elastic:features', False) %}
|
{% set FEATURES = salt['pillar.get']('elastic:features', False) %}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
{%- if grains.role == 'so-heavynode' %}
|
||||||
|
{%- set MANAGER = salt['pillar.get']('elasticsearch:mainip', '') %}
|
||||||
|
{%- else %}
|
||||||
|
{%- set MANAGER = salt['pillar.get']('global:managerip', '') %}
|
||||||
|
{% endif -%}
|
||||||
|
{%- set THREADS = salt['pillar.get']('logstash_settings:ls_input_threads', '') %}
|
||||||
|
{%- set access_key = salt['pillar.get']('global:access_key', '') %}
|
||||||
|
{%- set access_secret = salt['pillar.get']('global:access_secret', '') %}
|
||||||
|
input {
|
||||||
|
s3 {
|
||||||
|
access_key_id => "{{ access_key }}"
|
||||||
|
secret_access_key => "{{ access_secret }}"
|
||||||
|
endpoint => "http://{{ MANAGER }}:9595"
|
||||||
|
bucket => "logstash"
|
||||||
|
delete => true
|
||||||
|
interval => 10
|
||||||
|
codec => json
|
||||||
|
additional_settings => {
|
||||||
|
"force_path_style" => true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,7 +1,7 @@
|
|||||||
{%- if grains.role == 'so-heavynode' %}
|
{%- if grains.role == 'so-heavynode' %}
|
||||||
{%- set MANAGER = salt['pillar.get']('elasticsearch:mainip', '') %}
|
{%- set MANAGER = salt['pillar.get']('elasticsearch:mainip', '') %}
|
||||||
{%- else %}
|
{%- else %}
|
||||||
{%- set MANAGER = salt['pillar.get']('static:managerip', '') %}
|
{%- set MANAGER = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% endif -%}
|
{% endif -%}
|
||||||
{%- set THREADS = salt['pillar.get']('logstash_settings:ls_input_threads', '') %}
|
{%- set THREADS = salt['pillar.get']('logstash_settings:ls_input_threads', '') %}
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,17 @@
|
|||||||
|
{%- set MANAGER = salt['pillar.get']('global:managerip', '') -%}
|
||||||
|
{%- set access_key = salt['pillar.get']('global:access_key', '') %}
|
||||||
|
{%- set access_secret = salt['pillar.get']('global:access_secret', '') %}
|
||||||
|
output {
|
||||||
|
s3 {
|
||||||
|
access_key_id => "{{ access_key }}"
|
||||||
|
secret_access_key => "{{ access_secret}}"
|
||||||
|
endpoint => "http://{{ MANAGER }}:9595"
|
||||||
|
bucket => "logstash"
|
||||||
|
size_file => 2048
|
||||||
|
time_file => 1
|
||||||
|
codec => json
|
||||||
|
additional_settings => {
|
||||||
|
"force_path_style" => true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
{% set MANAGER = salt['pillar.get']('static:managerip', '') %}
|
{% set MANAGER = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set BATCH = salt['pillar.get']('logstash_settings:ls_pipeline_batch_size', 125) %}
|
{% set BATCH = salt['pillar.get']('logstash_settings:ls_pipeline_batch_size', 125) %}
|
||||||
output {
|
output {
|
||||||
redis {
|
redis {
|
||||||
|
|||||||
@@ -12,10 +12,10 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set managerproxy = salt['pillar.get']('static:managerupdate', '0') %}
|
{% set managerproxy = salt['pillar.get']('global:managerupdate', '0') %}
|
||||||
|
|
||||||
socore_own_saltstack:
|
socore_own_saltstack:
|
||||||
file.directory:
|
file.directory:
|
||||||
|
|||||||
@@ -13,8 +13,8 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
{% set access_key = salt['pillar.get']('manager:access_key', '') %}
|
{% set access_key = salt['pillar.get']('minio:access_key', '') %}
|
||||||
{% set access_secret = salt['pillar.get']('manager:access_secret', '') %}
|
{% set access_secret = salt['pillar.get']('minio:access_secret', '') %}
|
||||||
|
|
||||||
# Minio Setup
|
# Minio Setup
|
||||||
minioconfdir:
|
minioconfdir:
|
||||||
@@ -26,7 +26,14 @@ minioconfdir:
|
|||||||
|
|
||||||
miniodatadir:
|
miniodatadir:
|
||||||
file.directory:
|
file.directory:
|
||||||
- name: /nsm/minio/data
|
- name: /nsm/minio/data/
|
||||||
|
- user: 939
|
||||||
|
- group: 939
|
||||||
|
- makedirs: True
|
||||||
|
|
||||||
|
logstashbucket:
|
||||||
|
file.directory:
|
||||||
|
- name: /nsm/minio/data/logstash
|
||||||
- user: 939
|
- user: 939
|
||||||
- group: 939
|
- group: 939
|
||||||
- makedirs: True
|
- makedirs: True
|
||||||
@@ -40,12 +47,11 @@ minio:
|
|||||||
- hostname: so-minio
|
- hostname: so-minio
|
||||||
- user: socore
|
- user: socore
|
||||||
- port_bindings:
|
- port_bindings:
|
||||||
- 0.0.0.0:9000:9000
|
- 0.0.0.0:9595:9595
|
||||||
- environment:
|
- environment:
|
||||||
- MINIO_ACCESS_KEY: {{ access_key }}
|
- MINIO_ACCESS_KEY: {{ access_key }}
|
||||||
- MINIO_SECRET_KEY: {{ access_secret }}
|
- MINIO_SECRET_KEY: {{ access_secret }}
|
||||||
- binds:
|
- binds:
|
||||||
- /nsm/minio/data:/data:rw
|
- /nsm/minio/data:/data:rw
|
||||||
- /opt/so/conf/minio/etc:/root/.minio:rw
|
- /opt/so/conf/minio/etc:/root/.minio:rw
|
||||||
- entrypoint: "/usr/bin/docker-entrypoint.sh server /data"
|
- entrypoint: "/usr/bin/docker-entrypoint.sh server --address :9595 /data"
|
||||||
- network_mode: so-elastic-net
|
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{%- set MYSQLPASS = salt['pillar.get']('secrets:mysql', None) %}
|
{%- set MYSQLPASS = salt['pillar.get']('secrets:mysql', None) %}
|
||||||
{%- set MANAGERIP = salt['pillar.get']('static:managerip', '') %}
|
{%- set MANAGERIP = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set MAINIP = salt['pillar.get']('elasticsearch:mainip') %}
|
{% set MAINIP = salt['pillar.get']('elasticsearch:mainip') %}
|
||||||
{% set FLEETARCH = salt['grains.get']('role') %}
|
{% set FLEETARCH = salt['grains.get']('role') %}
|
||||||
@@ -10,7 +10,7 @@
|
|||||||
{% set MAININT = salt['pillar.get']('host:mainint') %}
|
{% set MAININT = salt['pillar.get']('host:mainint') %}
|
||||||
{% set MAINIP = salt['grains.get']('ip_interfaces').get(MAININT)[0] %}
|
{% set MAINIP = salt['grains.get']('ip_interfaces').get(MAININT)[0] %}
|
||||||
{% else %}
|
{% else %}
|
||||||
{% set MAINIP = salt['pillar.get']('static:managerip') %}
|
{% set MAINIP = salt['pillar.get']('global:managerip') %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
# MySQL Setup
|
# MySQL Setup
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{%- set managerip = salt['pillar.get']('manager:mainip', '') %}
|
{%- set managerip = salt['pillar.get']('manager:mainip', '') %}
|
||||||
{%- set FLEET_MANAGER = salt['pillar.get']('static:fleet_manager') %}
|
{%- set FLEET_MANAGER = salt['pillar.get']('global:fleet_manager') %}
|
||||||
{%- set FLEET_NODE = salt['pillar.get']('static:fleet_node') %}
|
{%- set FLEET_NODE = salt['pillar.get']('global:fleet_node') %}
|
||||||
{%- set FLEET_IP = salt['pillar.get']('static:fleet_ip', None) %}
|
{%- set FLEET_IP = salt['pillar.get']('global:fleet_ip', None) %}
|
||||||
# For more information on configuration, see:
|
# For more information on configuration, see:
|
||||||
# * Official English Documentation: http://nginx.org/en/docs/
|
# * Official English Documentation: http://nginx.org/en/docs/
|
||||||
# * Official Russian Documentation: http://nginx.org/ru/docs/
|
# * Official Russian Documentation: http://nginx.org/ru/docs/
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{%- set managerip = salt['pillar.get']('manager:mainip', '') %}
|
{%- set managerip = salt['pillar.get']('manager:mainip', '') %}
|
||||||
{%- set FLEET_MANAGER = salt['pillar.get']('static:fleet_manager') %}
|
{%- set FLEET_MANAGER = salt['pillar.get']('global:fleet_manager') %}
|
||||||
{%- set FLEET_NODE = salt['pillar.get']('static:fleet_node') %}
|
{%- set FLEET_NODE = salt['pillar.get']('global:fleet_node') %}
|
||||||
{%- set FLEET_IP = salt['pillar.get']('static:fleet_ip', None) %}
|
{%- set FLEET_IP = salt['pillar.get']('global:fleet_ip', None) %}
|
||||||
# For more information on configuration, see:
|
# For more information on configuration, see:
|
||||||
# * Official English Documentation: http://nginx.org/en/docs/
|
# * Official English Documentation: http://nginx.org/en/docs/
|
||||||
# * Official Russian Documentation: http://nginx.org/ru/docs/
|
# * Official Russian Documentation: http://nginx.org/ru/docs/
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{%- set managerip = salt['pillar.get']('manager:mainip', '') %}
|
{%- set managerip = salt['pillar.get']('manager:mainip', '') %}
|
||||||
{%- set FLEET_MANAGER = salt['pillar.get']('static:fleet_manager') %}
|
{%- set FLEET_MANAGER = salt['pillar.get']('global:fleet_manager') %}
|
||||||
{%- set FLEET_NODE = salt['pillar.get']('static:fleet_node') %}
|
{%- set FLEET_NODE = salt['pillar.get']('global:fleet_node') %}
|
||||||
{%- set FLEET_IP = salt['pillar.get']('static:fleet_ip', None) %}
|
{%- set FLEET_IP = salt['pillar.get']('global:fleet_ip', None) %}
|
||||||
# For more information on configuration, see:
|
# For more information on configuration, see:
|
||||||
# * Official English Documentation: http://nginx.org/en/docs/
|
# * Official English Documentation: http://nginx.org/en/docs/
|
||||||
# * Official Russian Documentation: http://nginx.org/ru/docs/
|
# * Official Russian Documentation: http://nginx.org/ru/docs/
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
{%- set managerip = salt['pillar.get']('manager:mainip', '') %}
|
{%- set managerip = salt['pillar.get']('manager:mainip', '') %}
|
||||||
{%- set FLEET_MANAGER = salt['pillar.get']('static:fleet_manager') %}
|
{%- set FLEET_MANAGER = salt['pillar.get']('global:fleet_manager') %}
|
||||||
{%- set FLEET_NODE = salt['pillar.get']('static:fleet_node') %}
|
{%- set FLEET_NODE = salt['pillar.get']('global:fleet_node') %}
|
||||||
{%- set FLEET_IP = salt['pillar.get']('static:fleet_ip', None) %}
|
{%- set FLEET_IP = salt['pillar.get']('global:fleet_ip', None) %}
|
||||||
# For more information on configuration, see:
|
# For more information on configuration, see:
|
||||||
# * Official English Documentation: http://nginx.org/en/docs/
|
# * Official English Documentation: http://nginx.org/en/docs/
|
||||||
# * Official Russian Documentation: http://nginx.org/ru/docs/
|
# * Official Russian Documentation: http://nginx.org/ru/docs/
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{%- set ip = salt['pillar.get']('static:managerip', '') %}
|
{%- set ip = salt['pillar.get']('global:managerip', '') %}
|
||||||
|
|
||||||
{
|
{
|
||||||
"enterprise_attack_url": "https://raw.githubusercontent.com/mitre/cti/master/enterprise-attack/enterprise-attack.json",
|
"enterprise_attack_url": "https://raw.githubusercontent.com/mitre/cti/master/enterprise-attack/enterprise-attack.json",
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
{% set FLEETMANAGER = salt['pillar.get']('static:fleet_manager', False) %}
|
{% set FLEETMANAGER = salt['pillar.get']('global:fleet_manager', False) %}
|
||||||
{% set FLEETNODE = salt['pillar.get']('static:fleet_node', False) %}
|
{% set FLEETNODE = salt['pillar.get']('global:fleet_node', False) %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
|
|
||||||
# Drop the correct nginx config based on role
|
# Drop the correct nginx config based on role
|
||||||
nginxconfdir:
|
nginxconfdir:
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{%- set ip = salt['pillar.get']('static:managerip', '') -%}
|
{%- set ip = salt['pillar.get']('global:managerip', '') -%}
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
default_salt_dir=/opt/so/saltstack/default
|
default_salt_dir=/opt/so/saltstack/default
|
||||||
|
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
@@ -13,7 +13,7 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
|
|
||||||
# Create the nodered group
|
# Create the nodered group
|
||||||
noderedgroup:
|
noderedgroup:
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{%- set MANAGER = salt['grains.get']('master') -%}
|
{%- set MANAGER = salt['grains.get']('master') -%}
|
||||||
{%- set SENSORONIKEY = salt['pillar.get']('static:sensoronikey', '') -%}
|
{%- set SENSORONIKEY = salt['pillar.get']('global:sensoronikey', '') -%}
|
||||||
{%- set CHECKININTERVALMS = salt['pillar.get']('pcap:sensor_checkin_interval_ms', 10000) -%}
|
{%- set CHECKININTERVALMS = salt['pillar.get']('pcap:sensor_checkin_interval_ms', 10000) -%}
|
||||||
{
|
{
|
||||||
"logFilename": "/opt/sensoroni/logs/sensoroni.log",
|
"logFilename": "/opt/sensoroni/logs/sensoroni.log",
|
||||||
|
|||||||
@@ -12,8 +12,8 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set INTERFACE = salt['pillar.get']('sensor:interface', 'bond0') %}
|
{% set INTERFACE = salt['pillar.get']('sensor:interface', 'bond0') %}
|
||||||
{% set BPF_STENO = salt['pillar.get']('steno:bpf', None) %}
|
{% set BPF_STENO = salt['pillar.get']('steno:bpf', None) %}
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% set MANAGERIP = salt['pillar.get']('manager:mainip', '') %}
|
{% set MANAGERIP = salt['pillar.get']('manager:mainip', '') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set MAINIP = salt['grains.get']('ip_interfaces').get(salt['pillar.get']('sensor:mainint', salt['pillar.get']('manager:mainint', salt['pillar.get']('elasticsearch:mainint', salt['pillar.get']('host:mainint')))))[0] %}
|
{% set MAINIP = salt['grains.get']('ip_interfaces').get(salt['pillar.get']('sensor:mainint', salt['pillar.get']('manager:mainint', salt['pillar.get']('elasticsearch:mainint', salt['pillar.get']('host:mainint')))))[0] %}
|
||||||
{%- set MYSQLPASS = salt['pillar.get']('secrets:mysql', None) -%}
|
{%- set MYSQLPASS = salt['pillar.get']('secrets:mysql', None) -%}
|
||||||
|
|||||||
@@ -10,7 +10,7 @@ def run():
|
|||||||
MINIONID = data['id']
|
MINIONID = data['id']
|
||||||
ACTION = data['data']['action']
|
ACTION = data['data']['action']
|
||||||
LOCAL_SALT_DIR = "/opt/so/saltstack/local"
|
LOCAL_SALT_DIR = "/opt/so/saltstack/local"
|
||||||
STATICFILE = f"{LOCAL_SALT_DIR}/pillar/static.sls"
|
STATICFILE = f"{LOCAL_SALT_DIR}/pillar/global.sls"
|
||||||
SECRETSFILE = f"{LOCAL_SALT_DIR}/pillar/secrets.sls"
|
SECRETSFILE = f"{LOCAL_SALT_DIR}/pillar/secrets.sls"
|
||||||
|
|
||||||
if MINIONID.split('_')[-1] in ['manager','eval','fleet','managersearch','standalone']:
|
if MINIONID.split('_')[-1] in ['manager','eval','fleet','managersearch','standalone']:
|
||||||
|
|||||||
@@ -12,8 +12,8 @@
|
|||||||
#
|
#
|
||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
|
|
||||||
# Redis Setup
|
# Redis Setup
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{%- set MANAGERIP = salt['pillar.get']('static:managerip', '') -%}
|
{%- set MANAGERIP = salt['pillar.get']('global:managerip', '') -%}
|
||||||
{%- set SENSORONIKEY = salt['pillar.get']('static:sensoronikey', '') -%}
|
{%- set SENSORONIKEY = salt['pillar.get']('global:sensoronikey', '') -%}
|
||||||
{
|
{
|
||||||
"logFilename": "/opt/sensoroni/logs/sensoroni-server.log",
|
"logFilename": "/opt/sensoroni/logs/sensoroni-server.log",
|
||||||
"server": {
|
"server": {
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
|
|
||||||
socdir:
|
socdir:
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{%- set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
{%- set MANAGER = salt['pillar.get']('manager:url_base', '') %}
|
||||||
{%- set HIVEKEY = salt['pillar.get']('static:hivekey', '') %}
|
{%- set HIVEKEY = salt['pillar.get']('global:hivekey', '') %}
|
||||||
{%- set CORTEXKEY = salt['pillar.get']('static:cortexorguserkey', '') %}
|
{%- set CORTEXKEY = salt['pillar.get']('global:cortexorguserkey', '') %}
|
||||||
|
|
||||||
[es]
|
[es]
|
||||||
es_url = http://{{MANAGER}}:9200
|
es_url = http://{{MANAGER}}:9200
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
{% set ES = salt['pillar.get']('static:managerip', '') %}
|
{% set ES = salt['pillar.get']('global:managerip', '') %}
|
||||||
|
|
||||||
alert: modules.so.playbook-es.PlaybookESAlerter
|
alert: modules.so.playbook-es.PlaybookESAlerter
|
||||||
elasticsearch_host: "{{ ES }}:9200"
|
elasticsearch_host: "{{ ES }}:9200"
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% set es = salt['pillar.get']('static:managerip', '') %}
|
{% set es = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set hivehost = salt['pillar.get']('static:managerip', '') %}
|
{% set hivehost = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set hivekey = salt['pillar.get']('static:hivekey', '') %}
|
{% set hivekey = salt['pillar.get']('global:hivekey', '') %}
|
||||||
alert: hivealerter
|
alert: hivealerter
|
||||||
|
|
||||||
hive_connection:
|
hive_connection:
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% set es = salt['pillar.get']('static:managerip', '') %}
|
{% set es = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set hivehost = salt['pillar.get']('static:managerip', '') %}
|
{% set hivehost = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set hivekey = salt['pillar.get']('static:hivekey', '') %}
|
{% set hivekey = salt['pillar.get']('global:hivekey', '') %}
|
||||||
alert: hivealerter
|
alert: hivealerter
|
||||||
|
|
||||||
hive_connection:
|
hive_connection:
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{%- set MANAGER_URL = salt['pillar.get']('manager:url_base', '') %}
|
{%- set MANAGER_URL = salt['pillar.get']('manager:url_base', '') %}
|
||||||
{%- set MANAGER_IP = salt['pillar.get']('static:managerip', '') %}
|
{%- set MANAGER_IP = salt['pillar.get']('global:managerip', '') %}
|
||||||
|
|
||||||
soctopusdir:
|
soctopusdir:
|
||||||
file.directory:
|
file.directory:
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
{% set manager = salt['grains.get']('master') %}
|
{% set manager = salt['grains.get']('master') %}
|
||||||
{% set managerip = salt['pillar.get']('static:managerip', '') %}
|
{% set managerip = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set HOSTNAME = salt['grains.get']('host') %}
|
{% set HOSTNAME = salt['grains.get']('host') %}
|
||||||
{% set global_ca_text = [] %}
|
{% set global_ca_text = [] %}
|
||||||
{% set global_ca_server = [] %}
|
{% set global_ca_server = [] %}
|
||||||
{% set MAININT = salt['pillar.get']('host:mainint') %}
|
{% set MAININT = salt['pillar.get']('host:mainint') %}
|
||||||
{% set MAINIP = salt['grains.get']('ip_interfaces').get(MAININT)[0] %}
|
{% set MAINIP = salt['grains.get']('ip_interfaces').get(MAININT)[0] %}
|
||||||
{% set CUSTOM_FLEET_HOSTNAME = salt['pillar.get']('static:fleet_custom_hostname', None) %}
|
{% set CUSTOM_FLEET_HOSTNAME = salt['pillar.get']('global:fleet_custom_hostname', None) %}
|
||||||
|
|
||||||
{% if grains.id.split('_')|last in ['manager', 'eval', 'standalone'] %}
|
{% if grains.id.split('_')|last in ['manager', 'eval', 'standalone'] %}
|
||||||
{% set trusttheca_text = salt['mine.get'](grains.id, 'x509.get_pem_entries')[grains.id]['/etc/pki/ca.crt']|replace('\n', '') %}
|
{% set trusttheca_text = salt['mine.get'](grains.id, 'x509.get_pem_entries')[grains.id]['/etc/pki/ca.crt']|replace('\n', '') %}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
{%- set mainint = salt['pillar.get']('sensor:mainint') %}
|
{%- set mainint = salt['pillar.get']('sensor:mainint') %}
|
||||||
{%- set ip = salt['grains.get']('ip_interfaces:' ~ mainint[0], salt['pillar.get']('sensor:mainip')) %}
|
{%- set ip = salt['grains.get']('ip_interfaces:' ~ mainint[0], salt['pillar.get']('sensor:mainip')) %}
|
||||||
{%- else %}
|
{%- else %}
|
||||||
{%- set ip = salt['pillar.get']('static:managerip') %}
|
{%- set ip = salt['pillar.get']('global:managerip') %}
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
logging_cfg: '/etc/strelka/logging.yaml'
|
logging_cfg: '/etc/strelka/logging.yaml'
|
||||||
limits:
|
limits:
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
{%- set mainint = salt['pillar.get']('sensor:mainint') %}
|
{%- set mainint = salt['pillar.get']('sensor:mainint') %}
|
||||||
{%- set ip = salt['grains.get']('ip_interfaces:' ~ mainint[0], salt['pillar.get']('sensor:mainip')) %}
|
{%- set ip = salt['grains.get']('ip_interfaces:' ~ mainint[0], salt['pillar.get']('sensor:mainip')) %}
|
||||||
{%- else %}
|
{%- else %}
|
||||||
{%- set ip = salt['pillar.get']('static:managerip') %}
|
{%- set ip = salt['pillar.get']('global:managerip') %}
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
conn:
|
conn:
|
||||||
server: '{{ ip }}:57314'
|
server: '{{ ip }}:57314'
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
{%- set mainint = salt['pillar.get']('sensor:mainint') %}
|
{%- set mainint = salt['pillar.get']('sensor:mainint') %}
|
||||||
{%- set ip = salt['grains.get']('ip_interfaces:' ~ mainint[0], salt['pillar.get']('sensor:mainip')) %}
|
{%- set ip = salt['grains.get']('ip_interfaces:' ~ mainint[0], salt['pillar.get']('sensor:mainip')) %}
|
||||||
{%- else %}
|
{%- else %}
|
||||||
{%- set ip = salt['pillar.get']('static:managerip') %}
|
{%- set ip = salt['pillar.get']('global:managerip') %}
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
server: ":57314"
|
server: ":57314"
|
||||||
coordinator:
|
coordinator:
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
{%- set mainint = salt['pillar.get']('sensor:mainint') %}
|
{%- set mainint = salt['pillar.get']('sensor:mainint') %}
|
||||||
{%- set ip = salt['grains.get']('ip_interfaces:' ~ mainint[0], salt['pillar.get']('sensor:mainip')) %}
|
{%- set ip = salt['grains.get']('ip_interfaces:' ~ mainint[0], salt['pillar.get']('sensor:mainip')) %}
|
||||||
{%- else %}
|
{%- else %}
|
||||||
{%- set ip = salt['pillar.get']('static:managerip') %}
|
{%- set ip = salt['pillar.get']('global:managerip') %}
|
||||||
{%- endif -%}
|
{%- endif -%}
|
||||||
coordinator:
|
coordinator:
|
||||||
addr: '{{ ip }}:6380'
|
addr: '{{ ip }}:6380'
|
||||||
|
|||||||
@@ -13,9 +13,9 @@
|
|||||||
# You should have received a copy of the GNU General Public License
|
# You should have received a copy of the GNU General Public License
|
||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
{%- set MANAGER = salt['grains.get']('master') %}
|
{%- set MANAGER = salt['grains.get']('master') %}
|
||||||
{%- set MANAGERIP = salt['pillar.get']('static:managerip', '') %}
|
{%- set MANAGERIP = salt['pillar.get']('global:managerip', '') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{%- set STRELKA_RULES = salt['pillar.get']('strelka:rules', '1') -%}
|
{%- set STRELKA_RULES = salt['pillar.get']('strelka:rules', '1') -%}
|
||||||
|
|
||||||
# Strelka config
|
# Strelka config
|
||||||
|
|||||||
@@ -14,9 +14,9 @@
|
|||||||
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
# along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
|
|
||||||
{% set interface = salt['pillar.get']('sensor:interface', 'bond0') %}
|
{% set interface = salt['pillar.get']('sensor:interface', 'bond0') %}
|
||||||
{% set ZEEKVER = salt['pillar.get']('static:zeekversion', '') %}
|
{% set ZEEKVER = salt['pillar.get']('global:zeekversion', '') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set BPF_NIDS = salt['pillar.get']('nids:bpf') %}
|
{% set BPF_NIDS = salt['pillar.get']('nids:bpf') %}
|
||||||
{% set BPF_STATUS = 0 %}
|
{% set BPF_STATUS = 0 %}
|
||||||
|
|||||||
@@ -11,7 +11,7 @@ HOME_NET: "[{{salt['pillar.get']('sensor:hnsensor')}}]"
|
|||||||
{% endload %}
|
{% endload %}
|
||||||
{% else %}
|
{% else %}
|
||||||
{% load_yaml as homenet %}
|
{% load_yaml as homenet %}
|
||||||
HOME_NET: "[{{salt['pillar.get']('static:hnmanager', '')}}]"
|
HOME_NET: "[{{salt['pillar.get']('global:hnmanager', '')}}]"
|
||||||
{% endload %}
|
{% endload %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
@@ -44,7 +44,7 @@ HOME_NET: "[{{salt['pillar.get']('static:hnmanager', '')}}]"
|
|||||||
{% endfor %}
|
{% endfor %}
|
||||||
{% set surimeta_evelog_index = surimeta_evelog_index[0] %}
|
{% set surimeta_evelog_index = surimeta_evelog_index[0] %}
|
||||||
|
|
||||||
{% if salt['pillar.get']('static:zeekversion', 'ZEEK') == 'SURICATA' %}
|
{% if salt['pillar.get']('global:zeekversion', 'ZEEK') == 'SURICATA' %}
|
||||||
{% do suricata_defaults.suricata.config.outputs[default_evelog_index]['eve-log'].types.extend(suricata_meta.suricata.config.outputs[surimeta_evelog_index]['eve-log'].types) %}
|
{% do suricata_defaults.suricata.config.outputs[default_evelog_index]['eve-log'].types.extend(suricata_meta.suricata.config.outputs[surimeta_evelog_index]['eve-log'].types) %}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% if grains['role'] == 'so-sensor' or grains['role'] == 'so-eval' %}
|
{% if grains['role'] == 'so-sensor' or grains['role'] == 'so-eval' %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
|
|
||||||
so-tcpreplay:
|
so-tcpreplay:
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
|
|
||||||
# Add Telegraf to monitor all the things.
|
# Add Telegraf to monitor all the things.
|
||||||
tgraflogdir:
|
tgraflogdir:
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{%- set MANAGERIP = salt['pillar.get']('static:managerip', '') %}
|
{%- set MANAGERIP = salt['pillar.get']('global:managerip', '') %}
|
||||||
{%- set CORTEXKEY = salt['pillar.get']('static:cortexorguserkey', '') %}
|
{%- set CORTEXKEY = salt['pillar.get']('global:cortexorguserkey', '') %}
|
||||||
{%- set HIVEPLAYSECRET = salt['pillar.get']('static:hiveplaysecret', '') %}
|
{%- set HIVEPLAYSECRET = salt['pillar.get']('global:hiveplaysecret', '') %}
|
||||||
|
|
||||||
# Secret Key
|
# Secret Key
|
||||||
# The secret key is used to secure cryptographic functions.
|
# The secret key is used to secure cryptographic functions.
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{%- set MANAGERIP = salt['pillar.get']('static:managerip', '') %}
|
{%- set MANAGERIP = salt['pillar.get']('global:managerip', '') %}
|
||||||
{%- set CORTEXPLAYSECRET = salt['pillar.get']('static:cortexplaysecret', '') %}
|
{%- set CORTEXPLAYSECRET = salt['pillar.get']('global:cortexplaysecret', '') %}
|
||||||
|
|
||||||
# Secret Key
|
# Secret Key
|
||||||
# The secret key is used to secure cryptographic functions.
|
# The secret key is used to secure cryptographic functions.
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{% set MANAGERIP = salt['pillar.get']('manager:mainip', '') %}
|
{% set MANAGERIP = salt['pillar.get']('manager:mainip', '') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
thehiveconfdir:
|
thehiveconfdir:
|
||||||
file.directory:
|
file.directory:
|
||||||
|
|||||||
@@ -1,18 +1,18 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# {%- set MANAGERIP = salt['pillar.get']('static:managerip', '') %}
|
# {%- set MANAGERIP = salt['pillar.get']('global:managerip', '') %}
|
||||||
# {%- set CORTEXUSER = salt['pillar.get']('static:cortexuser', 'cortexadmin') %}
|
# {%- set CORTEXUSER = salt['pillar.get']('global:cortexuser', 'cortexadmin') %}
|
||||||
# {%- set CORTEXPASSWORD = salt['pillar.get']('static:cortexpassword', 'cortexchangeme') %}
|
# {%- set CORTEXPASSWORD = salt['pillar.get']('global:cortexpassword', 'cortexchangeme') %}
|
||||||
# {%- set CORTEXKEY = salt['pillar.get']('static:cortexkey', '') %}
|
# {%- set CORTEXKEY = salt['pillar.get']('global:cortexkey', '') %}
|
||||||
# {%- set CORTEXORGNAME = salt['pillar.get']('static:cortexorgname', '') %}
|
# {%- set CORTEXORGNAME = salt['pillar.get']('global:cortexorgname', '') %}
|
||||||
# {%- set CORTEXORGUSER = salt['pillar.get']('static:cortexorguser', 'soadmin') %}
|
# {%- set CORTEXORGUSER = salt['pillar.get']('global:cortexorguser', 'soadmin') %}
|
||||||
# {%- set CORTEXORGUSERKEY = salt['pillar.get']('static:cortexorguserkey', '') %}
|
# {%- set CORTEXORGUSERKEY = salt['pillar.get']('global:cortexorguserkey', '') %}
|
||||||
|
|
||||||
default_salt_dir=/opt/so/saltstack/default
|
default_salt_dir=/opt/so/saltstack/default
|
||||||
|
|
||||||
cortex_clean(){
|
cortex_clean(){
|
||||||
sed -i '/^ cortexuser:/d' /opt/so/saltstack/local/pillar/static.sls
|
sed -i '/^ cortexuser:/d' /opt/so/saltstack/local/pillar/global.sls
|
||||||
sed -i '/^ cortexpassword:/d' /opt/so/saltstack/local/pillar/static.sls
|
sed -i '/^ cortexpassword:/d' /opt/so/saltstack/local/pillar/global.sls
|
||||||
sed -i '/^ cortexorguser:/d' /opt/so/saltstack/local/pillar/static.sls
|
sed -i '/^ cortexorguser:/d' /opt/so/saltstack/local/pillar/global.sls
|
||||||
}
|
}
|
||||||
|
|
||||||
cortex_init(){
|
cortex_init(){
|
||||||
|
|||||||
@@ -1,12 +1,12 @@
|
|||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
# {%- set MANAGERIP = salt['pillar.get']('static:managerip', '') %}
|
# {%- set MANAGERIP = salt['pillar.get']('global:managerip', '') %}
|
||||||
# {%- set THEHIVEUSER = salt['pillar.get']('static:hiveuser', 'hiveadmin') %}
|
# {%- set THEHIVEUSER = salt['pillar.get']('global:hiveuser', 'hiveadmin') %}
|
||||||
# {%- set THEHIVEPASSWORD = salt['pillar.get']('static:hivepassword', 'hivechangeme') %}
|
# {%- set THEHIVEPASSWORD = salt['pillar.get']('global:hivepassword', 'hivechangeme') %}
|
||||||
# {%- set THEHIVEKEY = salt['pillar.get']('static:hivekey', '') %}
|
# {%- set THEHIVEKEY = salt['pillar.get']('global:hivekey', '') %}
|
||||||
|
|
||||||
thehive_clean(){
|
thehive_clean(){
|
||||||
sed -i '/^ hiveuser:/d' /opt/so/saltstack/local/pillar/static.sls
|
sed -i '/^ hiveuser:/d' /opt/so/saltstack/local/pillar/global.sls
|
||||||
sed -i '/^ hivepassword:/d' /opt/so/saltstack/local/pillar/static.sls
|
sed -i '/^ hivepassword:/d' /opt/so/saltstack/local/pillar/global.sls
|
||||||
}
|
}
|
||||||
|
|
||||||
thehive_init(){
|
thehive_init(){
|
||||||
|
|||||||
@@ -1,11 +1,11 @@
|
|||||||
{%- set ZEEKVER = salt['pillar.get']('static:zeekversion', '') -%}
|
{%- set ZEEKVER = salt['pillar.get']('global:zeekversion', '') -%}
|
||||||
{%- set WAZUH = salt['pillar.get']('static:wazuh', '0') -%}
|
{%- set WAZUH = salt['pillar.get']('global:wazuh', '0') -%}
|
||||||
{%- set THEHIVE = salt['pillar.get']('manager:thehive', '0') -%}
|
{%- set THEHIVE = salt['pillar.get']('manager:thehive', '0') -%}
|
||||||
{%- set PLAYBOOK = salt['pillar.get']('manager:playbook', '0') -%}
|
{%- set PLAYBOOK = salt['pillar.get']('manager:playbook', '0') -%}
|
||||||
{%- set FREQSERVER = salt['pillar.get']('manager:freq', '0') -%}
|
{%- set FREQSERVER = salt['pillar.get']('manager:freq', '0') -%}
|
||||||
{%- set DOMAINSTATS = salt['pillar.get']('manager:domainstats', '0') -%}
|
{%- set DOMAINSTATS = salt['pillar.get']('manager:domainstats', '0') -%}
|
||||||
{%- set FLEETMANAGER = salt['pillar.get']('static:fleet_manager', False) -%}
|
{%- set FLEETMANAGER = salt['pillar.get']('global:fleet_manager', False) -%}
|
||||||
{%- set FLEETNODE = salt['pillar.get']('static:fleet_node', False) -%}
|
{%- set FLEETNODE = salt['pillar.get']('global:fleet_node', False) -%}
|
||||||
{%- set STRELKA = salt['pillar.get']('strelka:enabled', '0') -%}
|
{%- set STRELKA = salt['pillar.get']('strelka:enabled', '0') -%}
|
||||||
{% import_yaml 'salt/minion.defaults.yaml' as salt %}
|
{% import_yaml 'salt/minion.defaults.yaml' as salt %}
|
||||||
{% set saltversion = salt.salt.minion.version %}
|
{% set saltversion = salt.salt.minion.version %}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{%- if grains['role'] in ['so-manager', 'so-eval', 'so-managersearch', 'so-standalone'] %}
|
{%- if grains['role'] in ['so-manager', 'so-eval', 'so-managersearch', 'so-standalone'] %}
|
||||||
{%- set ip = salt['pillar.get']('static:managerip', '') %}
|
{%- set ip = salt['pillar.get']('global:managerip', '') %}
|
||||||
{%- elif grains['role'] == 'so-node' or grains['role'] == 'so-heavynode' %}
|
{%- elif grains['role'] == 'so-node' or grains['role'] == 'so-heavynode' %}
|
||||||
{%- set ip = salt['pillar.get']('elasticsearch:mainip', '') %}
|
{%- set ip = salt['pillar.get']('elasticsearch:mainip', '') %}
|
||||||
{%- elif grains['role'] == 'so-sensor' %}
|
{%- elif grains['role'] == 'so-sensor' %}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{%- if grains['role'] in ['so-manager', 'so-eval', 'so-managersearch', 'so-standalone'] %}
|
{%- if grains['role'] in ['so-manager', 'so-eval', 'so-managersearch', 'so-standalone'] %}
|
||||||
{%- set ip = salt['pillar.get']('static:managerip', '') %}
|
{%- set ip = salt['pillar.get']('global:managerip', '') %}
|
||||||
{%- elif grains['role'] == 'so-node' or grains['role'] == 'so-heavynode' %}
|
{%- elif grains['role'] == 'so-node' or grains['role'] == 'so-heavynode' %}
|
||||||
{%- set ip = salt['pillar.get']('elasticsearch:mainip', '') %}
|
{%- set ip = salt['pillar.get']('elasticsearch:mainip', '') %}
|
||||||
{%- elif grains['role'] == 'so-sensor' %}
|
{%- elif grains['role'] == 'so-sensor' %}
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
{%- set MANAGERIP = salt['pillar.get']('static:managerip', '') %}
|
{%- set MANAGERIP = salt['pillar.get']('global:managerip', '') %}
|
||||||
{%- set WAZUH_ENABLED = salt['pillar.get']('static:wazuh', '0') %}
|
{%- set WAZUH_ENABLED = salt['pillar.get']('global:wazuh', '0') %}
|
||||||
#!/bin/bash
|
#!/bin/bash
|
||||||
local_salt_dir=/opt/so/saltstack/local
|
local_salt_dir=/opt/so/saltstack/local
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{%- set HOSTNAME = salt['grains.get']('host', '') %}
|
{%- set HOSTNAME = salt['grains.get']('host', '') %}
|
||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
# Add ossec group
|
# Add ossec group
|
||||||
ossecgroup:
|
ossecgroup:
|
||||||
|
|||||||
@@ -11,6 +11,6 @@ installonly_limit={{ salt['pillar.get']('yum:config:installonly_limit', 2) }}
|
|||||||
bugtracker_url=http://bugs.centos.org/set_project.php?project_id=23&ref=http://bugs.centos.org/bug_report_page.php?category=yum
|
bugtracker_url=http://bugs.centos.org/set_project.php?project_id=23&ref=http://bugs.centos.org/bug_report_page.php?category=yum
|
||||||
distroverpkg=centos-release
|
distroverpkg=centos-release
|
||||||
|
|
||||||
{% if salt['pillar.get']('static:managerupdate', '0') %}
|
{% if salt['pillar.get']('global:managerupdate', '0') %}
|
||||||
proxy=http://{{ salt['pillar.get']('yum:config:proxy', salt['config.get']('master')) }}:3142
|
proxy=http://{{ salt['pillar.get']('yum:config:proxy', salt['config.get']('master')) }}:3142
|
||||||
{% endif %}
|
{% endif %}
|
||||||
@@ -1,5 +1,5 @@
|
|||||||
{% set VERSION = salt['pillar.get']('static:soversion', 'HH1.2.2') %}
|
{% set VERSION = salt['pillar.get']('global:soversion', 'HH1.2.2') %}
|
||||||
{% set IMAGEREPO = salt['pillar.get']('static:imagerepo') %}
|
{% set IMAGEREPO = salt['pillar.get']('global:imagerepo') %}
|
||||||
{% set MANAGER = salt['grains.get']('master') %}
|
{% set MANAGER = salt['grains.get']('master') %}
|
||||||
{% set BPF_ZEEK = salt['pillar.get']('zeek:bpf', {}) %}
|
{% set BPF_ZEEK = salt['pillar.get']('zeek:bpf', {}) %}
|
||||||
{% set BPF_STATUS = 0 %}
|
{% set BPF_STATUS = 0 %}
|
||||||
|
|||||||
@@ -1006,8 +1006,8 @@ manager_pillar() {
|
|||||||
cat "$pillar_file" >> "$setup_log" 2>&1
|
cat "$pillar_file" >> "$setup_log" 2>&1
|
||||||
}
|
}
|
||||||
|
|
||||||
manager_static() {
|
manager_global() {
|
||||||
local static_pillar="$local_salt_dir/pillar/static.sls"
|
local global_pillar="$local_salt_dir/pillar/global.sls"
|
||||||
|
|
||||||
if [ -z "$SENSOR_CHECKIN_INTERVAL_MS" ]; then
|
if [ -z "$SENSOR_CHECKIN_INTERVAL_MS" ]; then
|
||||||
SENSOR_CHECKIN_INTERVAL_MS=10000
|
SENSOR_CHECKIN_INTERVAL_MS=10000
|
||||||
@@ -1016,9 +1016,9 @@ manager_static() {
|
|||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Create a static file for global values
|
# Create a global file for global values
|
||||||
printf '%s\n'\
|
printf '%s\n'\
|
||||||
"static:"\
|
"global:"\
|
||||||
" soversion: $SOVERSION"\
|
" soversion: $SOVERSION"\
|
||||||
" hnmanager: $HNMANAGER"\
|
" hnmanager: $HNMANAGER"\
|
||||||
" ntpserver: $NTPSERVER"\
|
" ntpserver: $NTPSERVER"\
|
||||||
@@ -1117,10 +1117,13 @@ manager_static() {
|
|||||||
" shards: 5"\
|
" shards: 5"\
|
||||||
" warm: 7"\
|
" warm: 7"\
|
||||||
" close: 365"\
|
" close: 365"\
|
||||||
" delete: 45" > "$static_pillar"
|
" delete: 45"\
|
||||||
|
"minio:"\
|
||||||
|
" access_key: $ACCESS_KEY"\
|
||||||
|
" access_secret: $ACCESS_SECRET" > "$global_pillar"
|
||||||
|
|
||||||
printf '%s\n' '----' >> "$setup_log" 2>&1
|
printf '%s\n' '----' >> "$setup_log" 2>&1
|
||||||
cat "$static_pillar" >> "$setup_log" 2>&1
|
cat "$global_pillar" >> "$setup_log" 2>&1
|
||||||
}
|
}
|
||||||
|
|
||||||
minio_generate_keys() {
|
minio_generate_keys() {
|
||||||
@@ -1520,10 +1523,6 @@ sensor_pillar() {
|
|||||||
if [ "$HNSENSOR" != 'inherit' ]; then
|
if [ "$HNSENSOR" != 'inherit' ]; then
|
||||||
echo " hnsensor: $HNSENSOR" >> "$pillar_file"
|
echo " hnsensor: $HNSENSOR" >> "$pillar_file"
|
||||||
fi
|
fi
|
||||||
printf '%s\n'\
|
|
||||||
" access_key: $ACCESS_KEY"\
|
|
||||||
" access_secret: $ACCESS_SECRET"\
|
|
||||||
"" >> "$pillar_file"
|
|
||||||
|
|
||||||
printf '%s\n' '----' >> "$setup_log" 2>&1
|
printf '%s\n' '----' >> "$setup_log" 2>&1
|
||||||
cat "$pillar_file" >> "$setup_log" 2>&1
|
cat "$pillar_file" >> "$setup_log" 2>&1
|
||||||
|
|||||||
@@ -428,8 +428,8 @@ fi
|
|||||||
set_progress_str 11 'Updating sudoers file for soremote user'
|
set_progress_str 11 'Updating sudoers file for soremote user'
|
||||||
update_sudoers >> $setup_log 2>&1
|
update_sudoers >> $setup_log 2>&1
|
||||||
|
|
||||||
set_progress_str 12 'Generating manager static pillar'
|
set_progress_str 12 'Generating manager global pillar'
|
||||||
manager_static >> $setup_log 2>&1
|
manager_global >> $setup_log 2>&1
|
||||||
|
|
||||||
set_progress_str 13 'Generating manager pillar'
|
set_progress_str 13 'Generating manager pillar'
|
||||||
manager_pillar >> $setup_log 2>&1
|
manager_pillar >> $setup_log 2>&1
|
||||||
@@ -571,7 +571,7 @@ fi
|
|||||||
|
|
||||||
if [[ $is_fleet_standalone && $FLEETCUSTOMHOSTNAME != '' ]]; then
|
if [[ $is_fleet_standalone && $FLEETCUSTOMHOSTNAME != '' ]]; then
|
||||||
set_progress_str 77 "$(print_salt_state_apply 'fleet.event_update-custom-hostname')"
|
set_progress_str 77 "$(print_salt_state_apply 'fleet.event_update-custom-hostname')"
|
||||||
pillar_override="{\"static\":{\"fleet_custom_hostname\": \"$FLEETCUSTOMHOSTNAME\"}}"
|
pillar_override="{\"global\":{\"fleet_custom_hostname\": \"$FLEETCUSTOMHOSTNAME\"}}"
|
||||||
salt-call state.apply -l info fleet.event_update-custom-hostname pillar="$pillar_override" >> $setup_log 2>&1
|
salt-call state.apply -l info fleet.event_update-custom-hostname pillar="$pillar_override" >> $setup_log 2>&1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user