From 8bbe6fa30e1a38915a77150ba497fa95f19d933d Mon Sep 17 00:00:00 2001 From: tastytea Date: Tue, 9 Oct 2018 01:24:02 +0200 Subject: [PATCH] CI: replace gcc image with debian image --- .drone.yml | 61 +++++++++++++++++++++++++++++++++++++++++++----------- 1 file changed, 49 insertions(+), 12 deletions(-) diff --git a/.drone.yml b/.drone.yml index 2572881..22b3997 100644 --- a/.drone.yml +++ b/.drone.yml @@ -1,10 +1,23 @@ pipeline: gcc8: - image: gcc:8 + image: debian:stretch-slim pull: true + environment: + - LANG=C.utf8 commands: + - rm /etc/apt/apt.conf.d/docker-clean - apt-get update -q - - apt-get install -qy cmake libvsqlitepp-dev libboost-all-dev libxdg-basedir-dev qt5-default + - echo "APT::Default-Release \"stretch\";" >> /etc/apt/apt.conf.d/00default_release + - echo "deb http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu xenial main" >> /etc/apt/sources.list.d/ubuntu-toolchain-r.list + - apt-get install -qy gnupg + - gpg --keyserver hkp://keyserver.ubuntu.com --recv-keys 0x60c317803a41ba51845e371a1e9377a2ba9ef27f + - gpg --armor --export 0x60c317803a41ba51845e371a1e9377a2ba9ef27f | apt-key add - + - apt-get update -q + - apt-get install -qy build-essential cmake pkg-config + - apt-get install -qy -t xenial g++-8 + - update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 100 + - update-alternatives --set g++ /usr/bin/g++-8 + - apt-get install -qy libvsqlitepp-dev libboost-all-dev libxdg-basedir-dev qt5-default - apt-get install -qy rpm file - rm -rf build && mkdir -p build && cd build - cmake .. @@ -15,12 +28,28 @@ pipeline: - make package - cmake -DWITH_DEB=OFF -DWITH_RPM=ON .. - make package + volumes: + - /var/cache/debian-package-cache:/var/cache/apt/archives + gcc7: - image: gcc:7 + image: debian:stretch-slim pull: true + environment: + - LANG=C.utf8 commands: + - rm /etc/apt/apt.conf.d/docker-clean - apt-get update -q - - apt-get install -qy cmake libvsqlitepp-dev libboost-all-dev libxdg-basedir-dev qt5-default + - echo "APT::Default-Release \"stretch\";" >> /etc/apt/apt.conf.d/00default_release + - echo "deb http://ppa.launchpad.net/ubuntu-toolchain-r/test/ubuntu xenial main" >> /etc/apt/sources.list.d/ubuntu-toolchain-r.list + - apt-get install -qy gnupg + - gpg --keyserver hkp://keyserver.ubuntu.com --recv-keys 0x60c317803a41ba51845e371a1e9377a2ba9ef27f + - gpg --armor --export 0x60c317803a41ba51845e371a1e9377a2ba9ef27f | apt-key add - + - apt-get update -q + - apt-get install -qy build-essential cmake pkg-config + - apt-get install -qy -t xenial g++-7 + - update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-7 100 + - update-alternatives --set g++ /usr/bin/g++-7 + - apt-get install -qy libvsqlitepp-dev libboost-all-dev libxdg-basedir-dev qt5-default - apt-get install -qy rpm file - rm -rf build && mkdir -p build && cd build - cmake .. @@ -31,17 +60,19 @@ pipeline: - make package - cmake -DWITH_DEB=OFF -DWITH_RPM=ON .. - make package + volumes: + - /var/cache/debian-package-cache:/var/cache/apt/archives + gcc6: - image: gcc:6 + image: debian:stretch-slim pull: true + environment: + - LANG=C.utf8 commands: - - echo "deb http://deb.debian.org/debian jessie-backports main" >> /etc/apt/sources.list.d/backports.list - - echo "deb http://deb.debian.org/debian stretch main" >> /etc/apt/sources.list.d/stretch.list - - echo "APT::Default-Release \"jessie\";" >> /etc/apt/apt.conf.d/00default_release + - rm /etc/apt/apt.conf.d/docker-clean - apt-get update -q - - apt-get install -qy -t stretch libvsqlitepp-dev libboost-all-dev - - apt-get install -qy -t jessie-backports cmake - - apt-get install -qy libxdg-basedir-dev qt5-default + - apt-get install -qy build-essential cmake pkg-config + - apt-get install -qy libvsqlitepp-dev libboost-all-dev libxdg-basedir-dev qt5-default - apt-get install -qy rpm file - rm -rf build && mkdir -p build && cd build - cmake .. @@ -52,8 +83,12 @@ pipeline: - make package - cmake -DWITH_DEB=OFF -DWITH_RPM=ON .. - make package + volumes: + - /var/cache/debian-package-cache:/var/cache/apt/archives + + prepare_release: - image: gcc:6 + image: debian:stretch-slim pull: true when: event: tag @@ -61,6 +96,7 @@ pipeline: - cp -v build/whyblocked-${DRONE_TAG}_x86_64.tar.gz . - cp -v build/whyblocked_${DRONE_TAG}-0_amd64.deb . - cp -v build/whyblocked-${DRONE_TAG}-0.x86_64.rpm . + gitea_release: image: plugins/gitea-release pull: true @@ -77,6 +113,7 @@ pipeline: checksum: - sha256 - sha512 + notify: image: drillster/drone-email pull: true