diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index cfb88e8a365452a14f85d281029fde318a8de0e8..736a9ad406f3e17db5baf7b05dfb9198ff0ecc77 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -10,7 +10,7 @@ build-docs:
     - docs/_build/html
     expose_as: 'Documentation'
 
-publish:
+publish-pip:
   stage: deploy
   image: python:3.7
   script:
@@ -19,3 +19,18 @@ publish:
   - python -m twine upload --repository-url ${CI_API_V4_URL}/projects/${CI_PROJECT_ID}/packages/pypi dist/*
   rules:
     - if: '$CI_COMMIT_TAG =~ /v[0-9]+[.][0-9]+[.][0-9]+.*/'
+
+publish-apt:
+  image: debian:buster
+  stage: deploy
+  script:
+    - apt update
+    - apt-get install -y python3-all debhelper python3-pip git-buildpackage
+    - gbp dch --ignore-branch --debian-tag=v%\(version\)s
+    - dpkg-buildpackage -us -uc
+    - mkdir build
+    - mv ../*.deb build/
+  artifacts:
+    paths:
+      - build/*
+      - debian/changelog
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000000000000000000000000000000000000..f8ae9c605ecb4cca3b2db6183dcfa8f3a7d84f05
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,5 @@
+python3-ldapserver (0.0.1.dev0) unstable; urgency=medium
+
+  * Initial release.
+
+ -- Andreas Valder <nd@cccv.de>  Fri, 23 Jul 2021 18:02:31 +0200
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000000000000000000000000000000000000..aaab10c122db00a0fe10f52d4520c0dbdfd5f94f
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,19 @@
+Source: python3-ldapserver
+Section: python
+Priority: optional
+Maintainer: Andreas Valder <nd@cccv.de>
+Build-Depends:
+ debhelper-compat (= 12),
+ dh-python,
+ python3-all,
+ python3-setuptools,
+Standards-Version: 4.5.0
+Homepage: https://git.cccv.de/uffd/python-ldapserver
+Vcs-Git: https://git.cccv.de/uffd/python-ldapserver.git
+
+Package: python3-ldapserver
+Architecture: any
+Depends:
+ ${misc:Depends},
+ ${python3:Depends},
+Description: LDAP server request handler
diff --git a/debian/rules b/debian/rules
new file mode 100755
index 0000000000000000000000000000000000000000..3907ef908956a5b29b50f4840b174a9439d0ceb5
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,7 @@
+#!/usr/bin/make -f
+#export DH_VERBOSE = 1
+
+export PYBUILD_NAME=ldapserver
+
+%:
+	dh $@ --with python3 --buildsystem pybuild