mirror of
https://github.com/telekom-security/tpotce.git
synced 2025-07-02 04:52:11 +00:00
fixes #1320
This commit is contained in:
parent
35188ef28e
commit
efd5f4c54c
1 changed files with 28 additions and 26 deletions
4
docker/elk/logstash/dist/entrypoint.sh
vendored
4
docker/elk/logstash/dist/entrypoint.sh
vendored
|
@ -57,9 +57,10 @@ if [ "$MY_TPOT_TYPE" == "SENSOR" ];
|
|||
chmod 600 $MY_SENSOR_PRIVATEKEYFILE
|
||||
cp /usr/share/logstash/config/pipelines_sensor.yml /usr/share/logstash/config/pipelines.yml
|
||||
autossh -f -M 0 -4 -l $MY_HIVE_USERNAME -i $MY_SENSOR_PRIVATEKEYFILE -p 64295 -N -L64305:127.0.0.1:64305 $MY_HIVE_IP -o "ServerAliveInterval 30" -o "ServerAliveCountMax 3" -o "StrictHostKeyChecking=no" -o "UserKnownHostsFile=/dev/null"
|
||||
exit 0
|
||||
fi
|
||||
|
||||
if [ "$MY_TPOT_TYPE" != "SENSOR" ];
|
||||
then
|
||||
# Index Management is happening through ILM, but we need to put T-Pot ILM setting on ES.
|
||||
myTPOTILM=$(curl -s -XGET "http://elasticsearch:9200/_ilm/policy/tpot" | grep "Lifecycle policy not found: tpot" -c)
|
||||
if [ "$myTPOTILM" == "1" ];
|
||||
|
@ -91,6 +92,7 @@ if [ "$myTPOTILM" == "1" ];
|
|||
else
|
||||
echo "T-Pot ILM already configured or ES not available."
|
||||
fi
|
||||
fi
|
||||
echo
|
||||
|
||||
exec /usr/share/logstash/bin/logstash --config.reload.automatic
|
||||
|
|
Loading…
Reference in a new issue