2021-08-19 22:24:55 -04:00
|
|
|
kind: pipeline
|
2022-01-05 00:17:04 -05:00
|
|
|
type: docker
|
2021-08-21 02:27:33 -04:00
|
|
|
name: default
|
2021-08-19 22:24:55 -04:00
|
|
|
|
|
|
|
steps:
|
2021-08-21 02:27:33 -04:00
|
|
|
# use the step name to mock out the gethostname() call in our tests
|
|
|
|
- name: phosphoric-acid
|
2023-12-03 23:29:11 -05:00
|
|
|
image: python:3.9-slim-bullseye
|
2021-08-19 22:24:55 -04:00
|
|
|
# unfortunately we have to do everything in one step because there's no
|
|
|
|
# way to share system packages between steps
|
|
|
|
commands:
|
2021-08-21 02:27:33 -04:00
|
|
|
# install dependencies
|
2023-12-03 23:29:11 -05:00
|
|
|
- apt update
|
|
|
|
- apt install --no-install-recommends -y gcc libkrb5-dev libaugeas0
|
2021-08-19 22:24:55 -04:00
|
|
|
- python3 -m venv venv
|
|
|
|
- . venv/bin/activate
|
2023-12-03 23:29:11 -05:00
|
|
|
- venv/bin/pip install -r dev-requirements.txt -r requirements.txt
|
2021-08-20 14:17:00 -04:00
|
|
|
|
2021-08-19 22:24:55 -04:00
|
|
|
# lint
|
|
|
|
- flake8
|
2021-08-20 14:17:00 -04:00
|
|
|
|
|
|
|
# unit + integration tests
|
2023-12-03 23:29:11 -05:00
|
|
|
- bash -c ". .drone/phosphoric-acid-setup.sh && IMAGE__setup && CONTAINER__setup"
|
2021-08-20 14:17:00 -04:00
|
|
|
- pytest -v
|
|
|
|
|
|
|
|
services:
|
|
|
|
- name: auth1
|
2023-12-03 23:29:11 -05:00
|
|
|
image: debian:bullseye-slim
|
2021-08-20 14:17:00 -04:00
|
|
|
commands:
|
2023-12-03 23:29:11 -05:00
|
|
|
- bash -c ". .drone/auth1-setup.sh && IMAGE__setup && CONTAINER__setup"
|
2021-08-20 14:39:31 -04:00
|
|
|
- sleep infinity
|
2021-08-29 13:08:35 -04:00
|
|
|
- name: coffee
|
2023-12-03 23:29:11 -05:00
|
|
|
image: debian:bullseye-slim
|
2021-08-29 13:08:35 -04:00
|
|
|
commands:
|
2023-12-03 23:29:11 -05:00
|
|
|
- bash -c ". .drone/coffee-setup.sh && IMAGE__setup && CONTAINER__setup"
|
2021-08-29 13:08:35 -04:00
|
|
|
- sleep infinity
|
2021-08-21 03:20:40 -04:00
|
|
|
|
|
|
|
trigger:
|
|
|
|
branch:
|
|
|
|
- master
|