forked from torrust/torrust-index
-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (46 loc) · 1.39 KB
/
container.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
58
59
name: Container (Docker)
on:
push:
pull_request:
env:
CARGO_TERM_COLOR: always
jobs:
test:
name: Test
runs-on: ubuntu-latest
steps:
- id: checkout
name: Checkout Repository
uses: actions/checkout@v3
- id: setup
name: Setup Toolchain
uses: docker/setup-buildx-action@v2
- id: build
name: Build
uses: docker/build-push-action@v4
with:
push: false
load: true
tags: torrust-index-backend:local
cache-from: type=gha
cache-to: type=gha,mode=max
- id: inspect
name: Inspect
run: docker image inspect torrust-index-backend:local
- id: compose
name: Compose Applications
run: |
export TORRUST_IDX_BACK_CONFIG=$(cat config-idx-back.local.toml)
export TORRUST_TRACKER_CONFIG=$(cat config-tracker.local.toml)
docker compose build \
--build-arg TORRUST_IDX_BACK_CONFIG="$TORRUST_IDX_BACK_CONFIG" \
--build-arg TORRUST_TRACKER_CONFIG="$TORRUST_TRACKER_CONFIG"
- id: run
name: Run Applications
run: |
export TORRUST_IDX_BACK_CONFIG=$(cat config-idx-back.local.toml)
export TORRUST_TRACKER_CONFIG=$(cat config-tracker.local.toml)
docker compose up --detach
- id: check
name: Check Applications
run: docker ps