public inbox for igt-dev@lists.freedesktop.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Cc: igt-dev@lists.freedesktop.org,
	Petri Latvala <petri.latvala@intel.com>,
	Daniel Vetter <daniel@ffwll.ch>
Subject: Re: [igt-dev] [PATCH i-g-t] Add GitLab's CI/CD configuration
Date: Mon, 22 Oct 2018 11:22:50 +0200	[thread overview]
Message-ID: <20181022092250.GB324@phenom.ffwll.local> (raw)
In-Reply-To: <20181022084203.25118-1-arkadiusz.hiler@intel.com>

On Mon, Oct 22, 2018 at 11:42:03AM +0300, Arkadiusz Hiler wrote:
> The CI/CD pieline is configured the following way:
>  1. Build docker images and add them to repo's registry (manual step for
>     now, automation needs GitLab to be updated).
>  2. Build igt with meson on Debian and Feodra.
>  3. Run `ninja tests` on Fedora.
>  4. Build and publish docs as an artifact, for GitLab Pages.
> 
> Cc: Petri Latvala <petri.latvala@intel.com>
> Cc: Daniel Vetter <daniel@ffwll.ch>
> Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
> ---
>  .gitlab-ci.yml    | 69 +++++++++++++++++++++++++++++++++++++++++++++++
>  Dockerfile.debian | 28 +++++++++++++++++++
>  Dockerfile.fedora | 24 +++++++++++++++++
>  3 files changed, 121 insertions(+)
>  create mode 100644 .gitlab-ci.yml
>  create mode 100644 Dockerfile.debian
>  create mode 100644 Dockerfile.fedora
> 
> diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
> new file mode 100644
> index 00000000..0f3422a0
> --- /dev/null
> +++ b/.gitlab-ci.yml
> @@ -0,0 +1,69 @@
> +image: registry.freedesktop.org/drm/igt-gpu-tools/igt-fedora:latest
> +
> +stages:
> +  - containers
> +  - build
> +  - test
> +  - deploy
> +
> +build:tests-fedora:
> +  stage: build
> +  script:
> +    - meson build
> +    - ninja -C build
> +  artifacts:
> +    paths:
> +      - build
> +
> +build:tests-debian:
> +  image: registry.freedesktop.org/drm/igt-gpu-tools/igt-debian:latest
> +  stage: build
> +  script:
> +    - meson build
> +    - ninja -C build
> +
> +ninja:test:
> +  stage: test
> +  script:
> +    - ninja -C build test
> +
> +pages:
> +  stage: deploy
> +  script:
> +    - ninja -C build igt-gpu-tools-doc
> +    - cp -r build/docs/reference/igt-gpu-tools/html public
> +  artifacts:
> +    paths:
> +      - public
> +  only:
> +    - master
> +
> +containers:igt-debian:
> +  stage: containers
> +  when: manual
> +  image: docker:stable
> +  services:
> +    - docker:dind
> +  variables:
> +    DOCKER_HOST: tcp://docker:2375
> +    DOCKER_DRIVER: overlay2
> +  script:
> +    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.freedesktop.org
> +    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.freedesktop.org
> +    - docker build -t registry.freedesktop.org/drm/igt-gpu-tools/igt-debian -f Dockerfile.debian .
> +    - docker push registry.freedesktop.org/drm/igt-gpu-tools/igt-debian
> +
> +containers:igt-fedora:
> +  stage: containers
> +  when: manual

How do you trigger this? Is there some button on the UI?

Anyway, looks good enough to get us started.

Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>

Bits we could add:
- debian stable build (atm only autotools)
- build with the oldest meson we still claim to support (would need to git
  clone&install it in the docker image). Somewhat relevant since on oldest
  supported meson the docs building is different.
- Petri's idea to have the equivalent of an allyesconfig build

Cheers, Daniel

> +  image: docker:stable
> +  services:
> +    - docker:dind
> +  variables:
> +    DOCKER_HOST: tcp://docker:2375
> +    DOCKER_DRIVER: overlay2
> +  script:
> +    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.freedesktop.org
> +    - docker login -u gitlab-ci-token -p $CI_JOB_TOKEN registry.freedesktop.org
> +    - docker build -t registry.freedesktop.org/drm/igt-gpu-tools/igt-fedora -f Dockerfile.fedora .
> +    - docker push registry.freedesktop.org/drm/igt-gpu-tools/igt-fedora
> diff --git a/Dockerfile.debian b/Dockerfile.debian
> new file mode 100644
> index 00000000..a9f93957
> --- /dev/null
> +++ b/Dockerfile.debian
> @@ -0,0 +1,28 @@
> +FROM debian:stretch-backports
> +
> +RUN apt-get update
> +RUN apt-get install -y \
> +			gcc \
> +			flex \
> +			bison \
> +			pkg-config \
> +			libpciaccess-dev \
> +			libkmod-dev \
> +			libprocps-dev \
> +			libunwind-dev \
> +			libdw-dev \
> +			zlib1g-dev \
> +			liblzma-dev \
> +			libssl-dev \
> +			libcairo-dev \
> +			libudev-dev \
> +			libgsl-dev \
> +			libasound2-dev \
> +			libxmlrpc-core-c3-dev \
> +			libjson-c-dev \
> +			libcurl4-openssl-dev
> +
> +RUN apt-get install -t stretch-backports -y \
> +					meson \
> +					libdrm-dev \
> +					libdrm-intel1
> diff --git a/Dockerfile.fedora b/Dockerfile.fedora
> new file mode 100644
> index 00000000..58efa817
> --- /dev/null
> +++ b/Dockerfile.fedora
> @@ -0,0 +1,24 @@
> +FROM fedora:28
> +
> +RUN dnf install -y gcc \
> +		flex \
> +		meson \
> +		bison  \
> +		json-c \
> +		gtk-doc \
> +		xdotool \
> +		gsl-devel \
> +		kmod-devel \
> +		glib2-devel \
> +		cairo-devel \
> +		procps-devel \
> +		pixman-devel \
> +		libdrm-devel \
> +		openssl-devel \
> +		libudev-devel \
> +		xmlrpc-c-devel \
> +		elfutils-devel \
> +		libunwind-devel \
> +		python-docutils \
> +		libpciaccess-devel \
> +		alsa-lib-devel
> -- 
> 2.17.2
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
igt-dev mailing list
igt-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/igt-dev

  parent reply	other threads:[~2018-10-22  9:22 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-22  8:42 [igt-dev] [PATCH i-g-t] Add GitLab's CI/CD configuration Arkadiusz Hiler
2018-10-22  9:03 ` Petri Latvala
2018-10-22  9:22 ` Daniel Vetter [this message]
2018-10-22  9:58   ` Arkadiusz Hiler
2018-10-22 14:16     ` Daniel Vetter
2018-10-22 14:31       ` Arkadiusz Hiler
2018-10-22  9:47 ` Saarinen, Jani
2018-10-22 12:09 ` [igt-dev] [PATCH i-g-t v2] " Arkadiusz Hiler
2018-10-22 14:14   ` Arkadiusz Hiler
2018-10-22 14:18     ` Daniel Vetter
2018-10-22 14:24       ` Arkadiusz Hiler
2018-10-22 14:25         ` Daniel Vetter
2018-10-22 14:38           ` Arkadiusz Hiler
2018-10-22 14:59             ` Daniel Vetter
2018-10-23  7:32               ` Arkadiusz Hiler
2018-10-23 13:30                 ` Daniel Vetter
2018-10-24 16:27                   ` Arkadiusz Hiler
2018-10-22 20:43 ` [igt-dev] ✓ Fi.CI.BAT: success for Add GitLab's CI/CD configuration (rev2) Patchwork
2018-10-22 22:33 ` [igt-dev] ✓ Fi.CI.IGT: " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20181022092250.GB324@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=arkadiusz.hiler@intel.com \
    --cc=igt-dev@lists.freedesktop.org \
    --cc=petri.latvala@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox