-
Notifications
You must be signed in to change notification settings - Fork 0
57 lines (53 loc) · 1.26 KB
/
build.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
---
name: build
# Actions that take place on branches
# or are driven by pull-requests to the main/master branch.
# Here we build container images but don't push them
# and therefore do not require docker credentials.
# -----------------
# Control variables (GitHub Secrets)
# -----------------
#
# (n/a)
#
# -----------
# Environment (GitHub Environments)
# -----------
#
# Environment (n/a)
on:
push:
branches-ignore:
- 'main'
pull_request:
branches:
- 'main'
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.12'
- name: Install dependencies
run: |
pip install --upgrade pip
pip install -r build-requirements.txt
pip install -r requirements.txt
ansible-galaxy install -r requirements.yaml
- name: Lint
run: |
pre-commit run --all-files
ansible-lint
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build
uses: docker/build-push-action@v6
with:
context: operator
platforms: linux/amd64,linux/arm64