diff options
author | Mahdi Sarikhani | 2024-04-17 16:10:41 +0330 |
---|---|---|
committer | Mahdi Sarikhani | 2024-04-17 16:10:41 +0330 |
commit | 4cbecd6c4b3bffde06f410f0493fb5b51af5732a (patch) | |
tree | 32392787b052a0cbd5792889c00c96ed7f204cb2 /crowdsec.install | |
parent | eb7d63119105c593f2f58bce4292f75faf750ed9 (diff) | |
download | aur-crowdsec.tar.gz |
v1.6.1
Diffstat (limited to 'crowdsec.install')
-rw-r--r-- | crowdsec.install | 14 |
1 files changed, 0 insertions, 14 deletions
diff --git a/crowdsec.install b/crowdsec.install index 87a1afafd974..9f3493111921 100644 --- a/crowdsec.install +++ b/crowdsec.install @@ -8,23 +8,9 @@ post_install() { cscli hub update CSCLI_BIN_INSTALLED="/usr/bin/cscli" SILENT=true install_collection - - API=$(cscli config show --key "Config.API.Server") - if [ "${API}" = "nil" ]; then - LAPI=false - else - PORT=$(cscli config show --key "Config.API.Server.ListenURI" | cut -d ":" -f2) - fi - if [ "${LAPI}" = false ] || [ -z "$(ss -nlt "sport = ${PORT}" | grep -v ^State)" ]; then - systemctl start crowdsec - else - echo "Not attempting to start crowdsec, port ${PORT} is already used or lapi was disabled" - echo "This port is configured through /etc/crowdsec/config.yaml and /etc/crowdsec/local_api_credentials.yaml" - fi } pre_upgrade() { - echo " $1 => $2 " MAJOR=$(echo "$2" | awk -F '.' '{print $1}') MINOR=$(echo "$2" | awk -F '.' '{print $2}') |