#!/bin/bash
mkdir -p dist/etc/init
mv suricata.conf dist/etc/init

mkdir -p dist/etc/suricataLogger
mv SuricataLogger SuricataAlive.sh SuricataLogger.config dist/etc/suricataLogger

mkdir -p dist/etc/opt/suricataInstall
mv SuricataInstall.sh AddSuricataUser.sh SuricataInit.sh SuricataReg.sh SuricataAfterInstall.sh dist/etc/opt/suricataInstall
chmod +x dist/etc/opt/suricataInstall/*

fpm -s dir \
    -t deb \
    -C dist \
    -n bigcloud-suricata \
    -m "benesp32@fit.cvut.cz" \
    --after-install dist/etc/opt/suricataInstall/SuricataAfterInstall.sh  \
    --deb-no-default-config-files
