diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
new file mode 100644
index 0000000000000000000000000000000000000000..0a2ca865e901703573822bdc73abfc1ce8259af5
--- /dev/null
+++ b/.gitlab-ci.yml
@@ -0,0 +1,211 @@
+stages:
+  - build
+  - test
+  - upload
+
+variables:
+  DOCKER_IMAGE_BASE: registry.icinga.com/build-docker
+  ICINGA_BUILD_TYPE: snapshot
+  ICINGA_BUILD_UPSTREAM_BRANCH: feature/boost-asio
+
+.build: &build
+  stage: build
+  tags:
+    - docker
+  image: ${DOCKER_IMAGE_BASE}/${DOCKER_IMAGE}
+  script:
+    - icinga-build-package
+  cache:
+    key: "${CI_JOB_NAME}"
+    paths:
+      - ccache/
+      - 'icinga2.git'
+  artifacts:
+    paths:
+      - build/*
+    expire_in: 1 week
+
+.test: &test
+  stage: test
+  tags:
+    - docker
+  image: ${DOCKER_IMAGE_BASE}/${DOCKER_IMAGE}
+  script:
+    - find build/
+    - icinga-build-test
+
+.upload: &upload
+  stage: upload
+  tags:
+    - docker
+  image: ${DOCKER_IMAGE_BASE}/upload
+  script:
+    - find build/
+    - icinga-build-upload-aptly
+  only:
+    - tags
+
+###################################
+# Debian
+###################################
+build/debian/stretch:
+  <<: *build
+  variables:
+    DOCKER_IMAGE: debian/stretch
+
+test/debian/stretch:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: debian/stretch
+  dependencies:
+    - build/debian/stretch
+
+build/debian/stretch:x86:
+  <<: *build
+  variables:
+    DOCKER_IMAGE: debian/stretch:x86
+
+test/debian/stretch:x86:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: debian/stretch:x86
+  dependencies:
+    - build/debian/stretch:x86
+    - build/debian/stretch
+
+upload/debian/stretch:
+  <<: *upload
+  dependencies:
+    - build/debian/stretch:x86
+    - build/debian/stretch
+
+build/debian/jessie:
+  <<: *build
+  variables:
+    DOCKER_IMAGE: debian/jessie
+
+test/debian/jessie:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: debian/jessie
+  dependencies:
+    - build/debian/jessie
+
+build/debian/jessie:x86:
+  <<: *build
+  variables:
+    DOCKER_IMAGE: debian/jessie:x86
+
+test/debian/jessie:x86:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: debian/jessie:x86
+  dependencies:
+    - build/debian/jessie:x86
+    - build/debian/jessie
+
+upload/debian/jessie:
+  <<: *upload
+  dependencies:
+    - build/debian/jessie:x86
+    - build/debian/jessie
+
+###################################
+# Ubuntu
+###################################
+build/ubuntu/bionic:
+  <<: *build
+  variables:
+    ICINGA_BUILD_DEB_FLAVOR: stretch
+    DOCKER_IMAGE: ubuntu/bionic
+
+test/ubuntu/bionic:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: ubuntu/bionic
+  dependencies:
+    - build/ubuntu/bionic
+
+build/ubuntu/bionic:x86:
+  <<: *build
+  variables:
+    ICINGA_BUILD_DEB_FLAVOR: stretch
+    DOCKER_IMAGE: ubuntu/bionic:x86
+
+test/ubuntu/bionic:x86:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: ubuntu/bionic:x86
+  dependencies:
+    - build/ubuntu/bionic:x86
+    - build/ubuntu/bionic
+
+upload/ubuntu/bionic:
+  <<: *upload
+  dependencies:
+    - build/ubuntu/bionic:x86
+    - build/ubuntu/bionic
+
+build/ubuntu/xenial:
+  <<: *build
+  variables:
+    ICINGA_BUILD_DEB_FLAVOR: stretch
+    DOCKER_IMAGE: ubuntu/xenial
+
+test/ubuntu/xenial:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: ubuntu/xenial
+  dependencies:
+    - build/ubuntu/xenial
+
+build/ubuntu/xenial:x86:
+  <<: *build
+  variables:
+    ICINGA_BUILD_DEB_FLAVOR: stretch
+    DOCKER_IMAGE: ubuntu/xenial:x86
+
+test/ubuntu/xenial:x86:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: ubuntu/xenial:x86
+  dependencies:
+    - build/ubuntu/xenial:x86
+    - build/ubuntu/xenial
+
+upload/ubuntu/xenial:
+  <<: *upload
+  dependencies:
+    - build/ubuntu/xenial:x86
+    - build/ubuntu/xenial
+
+build/ubuntu/trusty:
+  <<: *build
+  variables:
+    DOCKER_IMAGE: ubuntu/trusty
+
+test/ubuntu/trusty:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: ubuntu/trusty
+  dependencies:
+    - build/ubuntu/trusty
+
+build/ubuntu/trusty:x86:
+  <<: *build
+  variables:
+    DOCKER_IMAGE: ubuntu/trusty:x86
+
+test/ubuntu/trusty:x86:
+  <<: *test
+  variables:
+    DOCKER_IMAGE: ubuntu/trusty:x86
+  dependencies:
+    - build/ubuntu/trusty:x86
+    - build/ubuntu/trusty
+
+upload/ubuntu/trusty:
+  <<: *upload
+  dependencies:
+    - build/ubuntu/trusty:x86
+    - build/ubuntu/trusty
diff --git a/jessie/debian/control b/jessie/debian/control
index 652783d99ace9d737dab456675fac3e167d77a78..844022480ed028e754a130b65371a3f5e2ffd980 100644
--- a/jessie/debian/control
+++ b/jessie/debian/control
@@ -2,28 +2,31 @@ Source: icinga2
 Section: admin
 Priority: extra
 Maintainer: Icinga Development Team <info@icinga.com>
-Build-Depends: bash-completion,
-               bison,
-               cmake (>= 2.8.7),
-               pkg-config,
-               debhelper (>= 9),
-               dh-systemd (>= 1.5),
-               libsystemd-dev,
-               flex,
-               g++ (>= 1.96),
-               libboost-dev,
-               libboost-program-options-dev,
-               libboost-regex-dev,
-               libboost-system-dev,
-               libboost-test-dev,
-               libboost-thread-dev,
-               libmysqlclient-dev,
-               libpq-dev,
-               libssl-dev,
-               libyajl-dev,
-               libedit-dev,
-               make (>= 3.81),
-               po-debconf
+Build-Depends:
+  bash-completion,
+  bison,
+  cmake (>= 2.8.7),
+  pkg-config,
+  debhelper (>= 9),
+  dh-systemd (>= 1.5),
+  libsystemd-dev,
+  flex,
+  g++ (>= 1.96),
+  libboost-dev (>= 1.66) | libboost1.67-dev | libboost1.67-icinga-dev,
+  libboost-context-dev (>= 1.66) | libboost-context1.67-dev | libboost-context1.67-icinga-dev,
+  libboost-coroutine-dev (>= 1.66) | libboost-coroutine1.67-dev | libboost-coroutine1.67-icinga-dev,
+  libboost-program-options-dev (>= 1.66) | libboost-program-options1.67-dev | libboost-program-options1.67-icinga-dev,
+  libboost-regex-dev (>= 1.66) | libboost-regex1.67-dev | libboost-regex1.67-icinga-dev,
+  libboost-system-dev (>= 1.66) | libboost-system1.67-dev | libboost-system1.67-icinga-dev,
+  libboost-test-dev (>= 1.66) | libboost-test1.67-dev | libboost-test1.67-icinga-dev,
+  libboost-thread-dev (>= 1.66) | libboost-thread1.67-dev | libboost-thread1.67-icinga-dev,
+  libmysqlclient-dev,
+  libpq-dev,
+  libssl-dev,
+  libyajl-dev,
+  libedit-dev,
+  make (>= 3.81),
+  po-debconf
 Standards-Version: 3.9.8
 Homepage: http://www.icinga.org
 Vcs-Browser: https://anonscm.debian.org/cgit/pkg-nagios/pkg-icinga2.git
diff --git a/jessie/debian/rules b/jessie/debian/rules
index 5a4fe4ee5aadf82fd247e785334718bb90f5760e..475c9226f9230ddea7ea61bbc2e7fb03fd252bed 100755
--- a/jessie/debian/rules
+++ b/jessie/debian/rules
@@ -6,6 +6,15 @@ LTO_BUILD = -DICINGA2_LTO_BUILD=On
 
 DEB_HOST_ARCH = $(shell dpkg-architecture -qDEB_HOST_ARCH)
 
+ifneq (,$(wildcard /usr/include/icinga-boost))
+BOOST_FLAGS = \
+  -DBoost_NO_BOOST_CMAKE=TRUE \
+  -DBoost_NO_SYSTEM_PATHS=TRUE \
+  -DBOOST_LIBRARYDIR=/usr/lib/$(DEB_HOST_MULTIARCH)/icinga-boost \
+  -DBOOST_INCLUDEDIR=/usr/include/icinga-boost \
+	-DCMAKE_INSTALL_RPATH=/usr/lib/$(DEB_HOST_MULTIARCH)/icinga-boost
+endif
+
 # disable unity/lto builds for arches with low memory
 ifneq ($(findstring $(DEB_HOST_ARCH), armhf),)
 	UNITY_BUILD = -DICINGA2_UNITY_BUILD=Off
@@ -22,8 +31,6 @@ ifneq ($(findstring $(DEB_HOST_ARCH), mipsel),)
 	LTO_BUILD = -DICINGA2_LTO_BUILD=Off
 endif
 
-
-
 %:
 	dh $@ --with systemd --with bash_completion
 
@@ -52,6 +59,7 @@ override_dh_auto_configure:
 		-DICINGA2_GIT_VERSION_INFO=false \
 		-DICINGA2_PLUGINDIR=/usr/lib/nagios/plugins \
 		-DUSE_SYSTEMD=ON \
+		$(BOOST_FLAGS) \
 		$(UNITY_BUILD) \
 		$(LTO_BUILD)
 
diff --git a/stretch/debian/control b/stretch/debian/control
index 3c3c87ee4d13c6b893f30246383fde9f8dd36b66..c80d7926f9e309f8996d804c4681abb925243f70 100644
--- a/stretch/debian/control
+++ b/stretch/debian/control
@@ -2,28 +2,31 @@ Source: icinga2
 Section: admin
 Priority: extra
 Maintainer: Icinga Development Team <info@icinga.com>
-Build-Depends: bash-completion,
-               bison,
-               cmake (>= 2.8.7),
-               cmake (>= 3.2.2) | pkg-config,
-               debhelper (>= 9),
-               dh-systemd (>= 1.5),
-               libsystemd-dev,
-               flex,
-               g++ (>= 1.96),
-               libboost-dev,
-               libboost-program-options-dev,
-               libboost-regex-dev,
-               libboost-system-dev,
-               libboost-test-dev,
-               libboost-thread-dev,
-               default-libmysqlclient-dev | libmysqlclient-dev,
-               libpq-dev,
-               libssl-dev,
-               libyajl-dev,
-               libedit-dev,
-               make (>= 3.81),
-               po-debconf
+Build-Depends:
+  bash-completion,
+  bison,
+  cmake (>= 2.8.7),
+  cmake (>= 3.2.2) | pkg-config,
+  debhelper (>= 9),
+  dh-systemd (>= 1.5),
+  libsystemd-dev,
+  flex,
+  g++ (>= 1.96),
+  libboost-dev (>= 1.66) | libboost1.67-dev | libboost1.67-icinga-dev,
+  libboost-context-dev (>= 1.66) | libboost-context1.67-dev | libboost-context1.67-icinga-dev,
+  libboost-coroutine-dev (>= 1.66) | libboost-coroutine1.67-dev | libboost-coroutine1.67-icinga-dev,
+  libboost-program-options-dev (>= 1.66) | libboost-program-options1.67-dev | libboost-program-options1.67-icinga-dev,
+  libboost-regex-dev (>= 1.66) | libboost-regex1.67-dev | libboost-regex1.67-icinga-dev,
+  libboost-system-dev (>= 1.66) | libboost-system1.67-dev | libboost-system1.67-icinga-dev,
+  libboost-test-dev (>= 1.66) | libboost-test1.67-dev | libboost-test1.67-icinga-dev,
+  libboost-thread-dev (>= 1.66) | libboost-thread1.67-dev | libboost-thread1.67-icinga-dev,
+  default-libmysqlclient-dev | libmysqlclient-dev,
+  libpq-dev,
+  libssl-dev,
+  libyajl-dev,
+  libedit-dev,
+  make (>= 3.81),
+  po-debconf
 Standards-Version: 3.9.8
 Homepage: http://www.icinga.org
 Vcs-Browser: https://anonscm.debian.org/cgit/pkg-nagios/pkg-icinga2.git
diff --git a/stretch/debian/rules b/stretch/debian/rules
index 1460e796e9b5fe15e62049230c789838d8e67a18..6d08ebb742e8587b1ca2fac21ba62f6aeabcdbf9 100755
--- a/stretch/debian/rules
+++ b/stretch/debian/rules
@@ -6,6 +6,15 @@ LTO_BUILD = -DICINGA2_LTO_BUILD=On
 
 DEB_HOST_ARCH = $(shell dpkg-architecture -qDEB_HOST_ARCH)
 
+ifneq (,$(wildcard /usr/include/icinga-boost))
+BOOST_FLAGS = \
+  -DBoost_NO_BOOST_CMAKE=TRUE \
+  -DBoost_NO_SYSTEM_PATHS=TRUE \
+  -DBOOST_LIBRARYDIR=/usr/lib/$(DEB_HOST_MULTIARCH)/icinga-boost \
+  -DBOOST_INCLUDEDIR=/usr/include/icinga-boost \
+	-DCMAKE_INSTALL_RPATH=/usr/lib/$(DEB_HOST_MULTIARCH)/icinga-boost
+endif
+
 # disable unity/lto builds for arches with low memory
 ifneq ($(findstring $(DEB_HOST_ARCH), armhf),)
 	UNITY_BUILD = -DICINGA2_UNITY_BUILD=Off
@@ -22,8 +31,6 @@ ifneq ($(findstring $(DEB_HOST_ARCH), mipsel),)
 	LTO_BUILD = -DICINGA2_LTO_BUILD=Off
 endif
 
-
-
 %:
 	dh $@ --with systemd --with bash_completion
 
@@ -52,6 +59,7 @@ override_dh_auto_configure:
 		-DICINGA2_GIT_VERSION_INFO=false \
 		-DICINGA2_PLUGINDIR=/usr/lib/nagios/plugins \
 		-DUSE_SYSTEMD=ON \
+		$(BOOST_FLAGS) \
 		$(UNITY_BUILD) \
 		$(LTO_BUILD)
 
diff --git a/testing/start_test.sh b/testing/start_test.sh
index f16cb0c90dbf4a5fb9d40c4bf6cc311f211dc4f5..c517eea3ab0b44cd65691af22bf86df23efa4720 100755
--- a/testing/start_test.sh
+++ b/testing/start_test.sh
@@ -2,15 +2,14 @@
 
 set -ex
 
-#This should work for any .deb Package
+if [ -d archive ]; then
+    cd archive
+    apt-ftparchive packages . > Packages
 
-cd archive
+    sudo su -c 'echo "deb [trusted=yes] file:$(pwd)/ ./" >>  /etc/apt/sources.list'
 
-apt-ftparchive packages . > Packages
-
-sudo su -c 'echo "deb [trusted=yes] file:$(pwd)/ ./" >>  /etc/apt/sources.list'
-
-sudo apt-get update
+    sudo apt-get update
+fi
 
 sudo DEBIAN_FRONTEND=noninteractive apt-get install --allow-unauthenticated -y icinga2 icinga2-ido-mysql mysql-server
 
diff --git a/trusty/debian/control b/trusty/debian/control
index 9f6162757228906a0e5e4baeaefe84ead62931da..27ca58756caac1fd736f0be981406bc00f305b67 100644
--- a/trusty/debian/control
+++ b/trusty/debian/control
@@ -6,26 +6,29 @@ Maintainer: Icinga Development Team <info@icinga.com>
 #Uploaders: Markus Frosch <lazyfrosch@debian.org>,
 #           Jan Wagner <waja@cyconet.org>,
 #           Alexander Wirt <formorer@debian.org>
-Build-Depends: bash-completion,
-               bison,
-               cmake (>= 2.8.7),
-               cmake (>= 3.2.2) | pkg-config,
-               debhelper (>= 9),
-               flex,
-               g++ (>= 1.96),
-               libboost-dev,
-               libboost-program-options-dev,
-               libboost-regex-dev,
-               libboost-system-dev,
-               libboost-test-dev,
-               libboost-thread-dev,
-               default-libmysqlclient-dev | libmysqlclient-dev,
-               libpq-dev,
-               libssl-dev,
-               libyajl-dev,
-               libedit-dev,
-               make (>= 3.81),
-               po-debconf
+Build-Depends:
+  bash-completion,
+  bison,
+  cmake (>= 2.8.7),
+  cmake (>= 3.2.2) | pkg-config,
+  debhelper (>= 9),
+  flex,
+  g++ (>= 1.96),
+  libboost-dev (>= 1.66) | libboost1.67-dev | libboost1.67-icinga-dev,
+  libboost-context-dev (>= 1.66) | libboost-context1.67-dev | libboost-context1.67-icinga-dev,
+  libboost-coroutine-dev (>= 1.66) | libboost-coroutine1.67-dev | libboost-coroutine1.67-icinga-dev,
+  libboost-program-options-dev (>= 1.66) | libboost-program-options1.67-dev | libboost-program-options1.67-icinga-dev,
+  libboost-regex-dev (>= 1.66) | libboost-regex1.67-dev | libboost-regex1.67-icinga-dev,
+  libboost-system-dev (>= 1.66) | libboost-system1.67-dev | libboost-system1.67-icinga-dev,
+  libboost-test-dev (>= 1.66) | libboost-test1.67-dev | libboost-test1.67-icinga-dev,
+  libboost-thread-dev (>= 1.66) | libboost-thread1.67-dev | libboost-thread1.67-icinga-dev,
+  default-libmysqlclient-dev | libmysqlclient-dev,
+  libpq-dev,
+  libssl-dev,
+  libyajl-dev,
+  libedit-dev,
+  make (>= 3.81),
+  po-debconf
 Standards-Version: 3.9.8
 Homepage: http://www.icinga.org
 Vcs-Browser: https://anonscm.debian.org/cgit/pkg-nagios/pkg-icinga2.git
diff --git a/trusty/debian/rules b/trusty/debian/rules
index 249d4cb21d1179facc0e3a15c5357aa6b008a89f..7bc79ffb684f94ec02257704b751a2dcd335f0f9 100755
--- a/trusty/debian/rules
+++ b/trusty/debian/rules
@@ -6,6 +6,15 @@ LTO_BUILD = -DICINGA2_LTO_BUILD=On
 
 DEB_HOST_ARCH = $(shell dpkg-architecture -qDEB_HOST_ARCH)
 
+ifneq (,$(wildcard /usr/include/icinga-boost))
+BOOST_FLAGS = \
+  -DBoost_NO_BOOST_CMAKE=TRUE \
+  -DBoost_NO_SYSTEM_PATHS=TRUE \
+  -DBOOST_LIBRARYDIR=/usr/lib/$(DEB_HOST_MULTIARCH)/icinga-boost \
+  -DBOOST_INCLUDEDIR=/usr/include/icinga-boost \
+	-DCMAKE_INSTALL_RPATH=/usr/lib/$(DEB_HOST_MULTIARCH)/icinga-boost
+endif
+
 # disable unity/lto builds for arches with low memory
 ifneq ($(findstring $(DEB_HOST_ARCH), armhf),)
 	UNITY_BUILD = -DICINGA2_UNITY_BUILD=Off
@@ -49,6 +58,7 @@ override_dh_auto_configure:
 		-DICINGA2_COMMAND_GROUP=www-data \
 		-DICINGA2_GIT_VERSION_INFO=false \
 		-DICINGA2_PLUGINDIR=/usr/lib/nagios/plugins \
+		$(BOOST_FLAGS) \
 		$(UNITY_BUILD) \
 		$(LTO_BUILD)