Skip to content

Commit

Permalink
Updates debian packaging.
Browse files Browse the repository at this point in the history
  • Loading branch information
gethvi committed Feb 1, 2024
1 parent 58c7d6c commit f410b85
Show file tree
Hide file tree
Showing 7 changed files with 38 additions and 5 deletions.
4 changes: 4 additions & 0 deletions .reuse/dep5
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,10 @@ Files: debian/*
Copyright: 2016 Intevation GmbH
License: AGPL-3.0-or-later

Files: debian/systemd/intelmq.service
Copyright: 2023 Filip Pokorný
License: AGPL-3.0-or-later

Files: debian/cron.d/intelmq-update-database
Copyright: 2020 gethvi <[email protected]>
License: AGPL-3.0-or-later
Expand Down
1 change: 1 addition & 0 deletions debian/conffiles
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
/etc/intelmq/harmonization.conf
/etc/intelmq/runtime.yaml
/etc/intelmq/intelmq.yaml
14 changes: 11 additions & 3 deletions debian/control
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,11 @@ Build-Depends: debhelper (>= 4.1.16),
python3-requests-mock,
python3-ruamel.yaml,
python3-setuptools,
python3-sphinx,
python3-sphinx-rtd-theme,
python3-termstyle (>= 0.1.10),
python3-fastapi,
python3-typing-extensions,
python3-multipart,
python3-gunicorn,
python3-tz,
quilt,
rsync,
Expand All @@ -32,6 +34,7 @@ Architecture: all
Depends: bash-completion,
cron,
jq,
dbconfig-sqlite3 | dbconfig-no-thanks,
python3-dateutil (>= 2.5),
python3-dnspython (>= 2.0.0),
python3-openssl,
Expand All @@ -40,12 +43,17 @@ Depends: bash-completion,
python3-requests (>= 2.2.0),
python3-ruamel.yaml,
python3-termstyle (>= 0.1.10),
python3-fastapi,
python3-typing-extensions,
python3-multipart,
python3-uvicorn,
python3-uvloop,
python3-httptools,
python3-tz,
python3-importlib-metadata,
redis-server,
systemd,
${misc:Depends},
${sphinxdoc:Depends},
${python3:Depends}
Suggests: python3-geoip2 (>= 2.2.0),
python3-imbox (>= 0.8),
Expand Down
2 changes: 2 additions & 0 deletions debian/intelmq.install
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
debian/cron.d/intelmq-update-database etc/cron.d/
debian/systemd/intelmq.service lib/systemd/system/
contrib/logrotate/intelmq etc/logrotate.d/
contrib/bash-completion/intelmqctl usr/share/bash-completion/completions/
contrib/bash-completion/intelmqdump usr/share/bash-completion/completions/
intelmq/bots/experts/modify/examples/* usr/share/doc/intelmq/bots/experts/modify/examples/
intelmq/etc/runtime.yaml etc/intelmq/
intelmq/etc/harmonization.conf etc/intelmq/
intelmq/etc/intelmq.yaml etc/intelmq/
5 changes: 3 additions & 2 deletions debian/rules
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,13 @@ BOTDOCS := $(foreach bot,$(BOTS),$(wildcard $(bot)/*.md))
# Wed, 23 Mar 2016 17:49:26 +0000
export PYBUILD_NAME=intelmq
%:
dh $@ --with python3,sphinxdoc --without python2 --buildsystem=pybuild --with quilt --with systemd
dh $@ --with python3 --without python2 --buildsystem=pybuild --with quilt --with systemd

build:
if [ $(CODENAME) = 'xenial' ] || [ $(CODENAME) = 'jessie' ]; then\
patch -p1 setup.py debian/patches/fix-dnspython-name.patch;\
fi
dh build --with python3,sphinxdoc --without python2 --buildsystem=pybuild --with quilt --with systemd
dh build --with python3 --without python2 --buildsystem=pybuild --with quilt --with systemd
# These tests frequently fail on Ubuntu and Debian systems.
# On some systems this command will be executed twice, so -f
rm -rf intelmq/tests/bots/collectors/tcp/
Expand All @@ -39,6 +39,7 @@ override_dh_auto_install: $(BOTDOCS)
dh_auto_install
# create directories
mkdir -p debian/intelmq/var/log/intelmq
mkdir -p debian/intelmq/var/lib/intelmq/server
mkdir -p debian/intelmq/var/lib/intelmq/bots/file-output
mkdir -p debian/intelmq/etc/logrotate.d
mkdir -p debian/intelmq/var/lib/intelmq/bots/modify/
Expand Down
17 changes: 17 additions & 0 deletions debian/systemd/intelmq.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
[Unit]
Description=IntelMQ server app
After=network.target

[Service]
User=intelmq
Group=intelmq
RuntimeDirectory=intelmq
WorkingDirectory=/var/lib/intelmq/
ExecStart=intelmq server start
ExecReload=/bin/kill -s HUP $MAINPID
KillMode=mixed
TimeoutStopSec=5
PrivateTmp=true

[Install]
WantedBy=multi-user.target
Empty file.

0 comments on commit f410b85

Please sign in to comment.