-
Notifications
You must be signed in to change notification settings - Fork 162
65 lines (63 loc) · 2.16 KB
/
e2e.yml
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
58
59
60
61
62
63
64
65
name: Turbinia E2E Test
on: [push, pull_request]
jobs:
e2e-test:
name: Run local stack e2e test
strategy:
matrix:
os:
- ubuntu-22.04
gift_ppa_track: ["staging", "stable"]
runs-on: ${{ matrix.os }}
steps:
- name: checkout
uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Build Turbinia API server Docker image
uses: docker/build-push-action@v5
with:
file: docker/api_server/Dockerfile
context: .
load: true
tags: turbinia-api-server-dev
cache-from: type=gha,scope=api-server
cache-to: type=gha,mode=max,scope=api-server
- name: Build Turbinia Server Docker image
uses: docker/build-push-action@v5
with:
file: docker/server/Dockerfile
context: .
load: true
tags: turbinia-server-dev
cache-from: type=gha,scope=server
cache-to: type=gha,mode=max,scope=server
- name: Buid Turbinia Worker Docker image
uses: docker/build-push-action@v5
with:
file: docker/worker/Dockerfile
context: .
build-args: |
"PPA_TRACK=${{ matrix.gift_ppa_track }}"
load: true
tags: turbinia-worker-dev
cache-from: type=gha,scope=worker
cache-to: type=gha,mode=max,scope=worker
- name: Prepare Turbinia configuration
run: |
mkdir ./conf
sed -f ./docker/local/local-config.sed ./turbinia/config/turbinia_config_tmpl.py > ./conf/turbinia.conf
- name: Display Turbinia configuration
run: |
cat ./conf/turbinia.conf
- name: Patch docker-compose config to use locally build images
run: |
sed -i -e 's/#image: "t/image: "t/g' -e 's/image: "u/#image: "u/g' ./docker/local/docker-compose.yml
- name: Update pip
run: python -m pip install --upgrade pip
- name: Install turbinia-client
run: pip install turbinia-client
- name: Run E2E test
run: |
chmod +x ./turbinia/e2e/e2e-local.sh
./turbinia/e2e/e2e-local.sh