-
-
Notifications
You must be signed in to change notification settings - Fork 1
115 lines (112 loc) · 3.28 KB
/
libs.yml
File metadata and controls
115 lines (112 loc) · 3.28 KB
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
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
name: build:libs
on:
push:
branches: [ main ]
paths:
- .build/conf/libs/linux/compile.Dockerfile
- .github/workflows/libs.yml
pull_request:
paths:
- .build/conf/libs/linux/compile.Dockerfile
- .github/workflows/libs.yml
branches: [ main ]
jobs:
base:
runs-on: ubuntu-latest
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v4
- uses: docker/setup-buildx-action@v3
id: buildx
with:
install: true
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v5
with:
push: true
cache-from: type=gha
cache-to: type=gha,mode=max
tags: lthn/build:libs-linux-base
file: .build/conf/libs/linux/compile.Dockerfile
libs:
runs-on: ubuntu-latest
needs: base
strategy:
max-parallel: 5
fail-fast: false
matrix:
build: [
libx, utils, cmake, boost, fontconfig
]
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v4
- uses: docker/setup-buildx-action@v3
id: buildx
with:
install: true
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v5
with:
push: true
cache-from: ghcr.io/letheanVPN/build:lib-linux-${{ matrix.build }}
tags: lthn/build:lib-linux-${{ matrix.build }}
file: .build/conf/libs/linux/${{ matrix.build }}.Dockerfile
builder:
runs-on: ubuntu-latest
needs: libs
strategy:
max-parallel: 3
fail-fast: false
matrix:
build: [
linux, windows, android
]
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.1
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v4
- uses: docker/setup-buildx-action@v3
id: buildx
with:
install: true
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Login to DockerHub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Build and push
id: docker_build
uses: docker/build-push-action@v5
with:
push: true
context: .build/src
build-args: BUILD=${{ matrix.build }}
tags: ghcr.io/letheanVPN/build:${{ matrix.build }}
file: .build/conf/libs/${{ matrix.build }}.Dockerfile