# SPDX-License-Identifier: LGPL-2.1-or-later
#
# Copyright (C) 2021, 2022 Collabora Limited
# Author: Guillaume Tucker
# Author: Jeny Sadadia
version: '3'
services:
monitor: &base-service
container_name: 'kernelci-pipeline-monitor'
image: 'kernelci/staging-kernelci'
env_file: ['.env']
stop_signal: 'SIGINT'
command:
- './pipeline/monitor.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
volumes: &base-volumes
- './src:/home/kernelci/pipeline'
- './config:/home/kernelci/config'
- './logs:/home/kernelci/logs'
extra_hosts:
- "host.docker.internal:host-gateway"
restart: on-failure
result_summary:
container_name: 'kernelci-pipeline-result-summary'
image: 'kernelci/staging-kernelci'
env_file: ['.env']
stop_signal: 'SIGINT'
entrypoint:
- './pipeline/result_summary.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
- '--config=${CONFIG:-/home/kernelci/config/result-summary.yaml}'
volumes:
- './src:/home/kernelci/pipeline'
- './config:/home/kernelci/config'
- './data/output:/home/kernelci/data/output'
- './logs:/home/kernelci/logs'
#restart: on-failure
scheduler: &scheduler
container_name: 'kernelci-pipeline-scheduler'
image: 'kernelci/staging-kernelci'
env_file: ['.env']
stop_signal: 'SIGINT'
command:
- './pipeline/scheduler.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'loop'
- '--runtimes=shell'
- '--name=scheduler'
volumes:
- './src:/home/kernelci/pipeline'
- './config:/home/kernelci/config'
- './data/output:/home/kernelci/data/output'
- './data/k8s-credentials/.kube:/home/kernelci/.kube'
- './data/k8s-credentials/.config/gcloud:/home/kernelci/.config/gcloud'
- './data/k8s-credentials/.azure:/home/kernelci/.azure'
- './logs:/home/kernelci/logs'
extra_hosts:
- "host.docker.internal:host-gateway"
restart: on-failure
scheduler-docker:
<<: *scheduler
container_name: 'kernelci-pipeline-scheduler-docker'
user: root # Docker-in-Docker
working_dir: /home/kernelci
command:
- './pipeline/scheduler.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'loop'
- '--runtimes=docker'
- '--name=scheduler_docker'
volumes:
- './src:/home/kernelci/pipeline'
- './config:/home/kernelci/config'
- './data/output:/home/kernelci/data/output'
- './.docker-env:/home/kernelci/.docker-env'
- '/var/run/docker.sock:/var/run/docker.sock' # Docker-in-Docker
- './logs:/home/kernelci/logs'
extra_hosts:
- "host.docker.internal:host-gateway"
scheduler-lava:
<<: *scheduler
container_name: 'kernelci-pipeline-scheduler-lava'
command:
- './pipeline/scheduler.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'loop'
- '--name=scheduler_lava'
- '--runtimes'
- 'lava-collabora'
- 'lava-collabora-staging'
- 'lava-broonie'
- 'lava-baylibre'
- 'lava-qualcomm'
- 'lava-cip'
extra_hosts:
- "host.docker.internal:host-gateway"
scheduler-k8s:
<<: *scheduler
container_name: 'kernelci-pipeline-scheduler-k8s'
image: 'kernelci/staging-k8s:kernelci'
command:
- './pipeline/scheduler.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'loop'
- '--name=scheduler_k8s'
- '--runtimes'
- 'k8s-gke-eu-west4'
- 'k8s-all'
extra_hosts:
- "host.docker.internal:host-gateway"
tarball:
<<: *base-service
container_name: 'kernelci-pipeline-tarball'
command:
- './pipeline/tarball.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
- '--name=tarball'
volumes:
- './src:/home/kernelci/pipeline'
- './config:/home/kernelci/config'
- './data/ssh:/home/kernelci/data/ssh'
- './data/src:/home/kernelci/data/src'
- './data/output:/home/kernelci/data/output'
- './logs:/home/kernelci/logs'
extra_hosts:
- "host.docker.internal:host-gateway"
trigger:
<<: *base-service
container_name: 'kernelci-pipeline-trigger'
command:
- './pipeline/trigger.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
- '--trees=kernelci'
- '--name=trigger'
extra_hosts:
- "host.docker.internal:host-gateway"
regression_tracker:
<<: *base-service
container_name: 'kernelci-pipeline-regression_tracker'
command:
- '/usr/bin/env'
- 'python3'
- '/home/kernelci/pipeline/regression_tracker.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
extra_hosts:
- "host.docker.internal:host-gateway"
test_report:
<<: *base-service
container_name: 'kernelci-pipeline-test_report'
command:
- '/usr/bin/env'
- 'python3'
- '/home/kernelci/pipeline/test_report.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'loop'
extra_hosts:
- "host.docker.internal:host-gateway"
timeout:
<<: *base-service
container_name: 'kernelci-pipeline-timeout'
command:
- '/usr/bin/env'
- 'python3'
- '/home/kernelci/pipeline/timeout.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
- '--mode=timeout'
extra_hosts:
- "host.docker.internal:host-gateway"
timeout-closing:
<<: *base-service
container_name: 'kernelci-pipeline-closing'
command:
- '/usr/bin/env'
- 'python3'
- '/home/kernelci/pipeline/timeout.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
- '--mode=closing'
extra_hosts:
- "host.docker.internal:host-gateway"
timeout-holdoff:
<<: *base-service
container_name: 'kernelci-pipeline-holdoff'
command:
- '/usr/bin/env'
- 'python3'
- '/home/kernelci/pipeline/timeout.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
- '--mode=holdoff'
extra_hosts:
- "host.docker.internal:host-gateway"
patchset:
<<: *base-service
container_name: 'kernelci-pipeline-patchset'
command:
- './pipeline/patchset.py'
- '--settings=${KCI_SETTINGS:-/home/kernelci/config/kernelci.toml}'
- 'run'
- '--name=patchset'
volumes:
- './src:/home/kernelci/pipeline'
- './config:/home/kernelci/config'
- './data/ssh:/home/kernelci/data/ssh'
- './data/src:/home/kernelci/data/src'
- './data/output:/home/kernelci/data/output'
- './logs:/home/kernelci/logs'