Skip to content

Commit 44e4d8e

Browse files
committed
Added mixes for swoole and openswoole
1 parent ed8768e commit 44e4d8e

File tree

5 files changed

+109
-278
lines changed

5 files changed

+109
-278
lines changed

.github/workflows/docker-commit.yml

Lines changed: 25 additions & 74 deletions
Original file line numberDiff line numberDiff line change
@@ -70,82 +70,31 @@ jobs:
7070
linux/arm64
7171
linux/arm/v7
7272
73-
push_octane:
73+
push_swoole:
7474
if: "!contains(github.event.head_commit.message, 'skip ci')"
7575

7676
runs-on: ubuntu-latest
7777

78-
name: Tag Commit (Octane, ${{ matrix.base-tag }})
78+
name: Tag Commit (${{ matrix.swoole }}/v${{ matrix.swoole-version }} with ${{ matrix.php-tag }})
7979

8080
strategy:
8181
fail-fast: false
8282
matrix:
83-
base-tag:
84-
- 5.0-php8.1-alpine
85-
- 5.0-php8.0-alpine
86-
- 4.8-php8.1-alpine
87-
- 4.8-php8.0-alpine
88-
89-
steps:
90-
- uses: actions/checkout@v3
91-
92-
- name: Set up QEMU
93-
uses: docker/setup-qemu-action@v2
94-
95-
- name: Docker meta
96-
id: docker_meta
97-
uses: docker/metadata-action@v4.0.1
98-
with:
99-
images: quay.io/renokico/laravel-base
100-
tags: |
101-
type=ref,event=pr,suffix=-octane-${{ matrix.base-tag }}
102-
type=raw,value=octane-${{ github.sha }}-${{ matrix.base-tag }}
103-
labels: |
104-
quay.expires-after=7d
105-
106-
- name: Set up Docker Buildx
107-
uses: docker/setup-buildx-action@v2
108-
109-
- name: Login to Quay
110-
uses: docker/login-action@v2
111-
with:
112-
registry: quay.io
113-
username: ${{ secrets.DOCKER_REPOSITORY_USERNAME }}
114-
password: ${{ secrets.DOCKER_REPOSITORY_TOKEN }}
115-
116-
- name: Build and push
117-
id: docker
118-
uses: docker/build-push-action@v3
119-
with:
120-
push: true
121-
context: .
122-
tags: ${{ steps.docker_meta.outputs.tags }}
123-
labels: ${{ steps.docker_meta.outputs.labels }}
124-
file: Dockerfile.octane
125-
build-args: |
126-
BASE_TAG=${{ matrix.base-tag }}
127-
cache-from: |
128-
type=gha,scope=octane
129-
cache-to: |
130-
type=gha,scope=octane
131-
platforms: |
132-
linux/amd64
133-
linux/arm64
134-
linux/arm/v7
135-
136-
push_openswoole:
137-
if: "!contains(github.event.head_commit.message, 'skip ci')"
138-
139-
runs-on: ubuntu-latest
140-
141-
name: Tag Commit (Openswoole for Octane, ${{ matrix.base-tag }})
142-
143-
strategy:
144-
fail-fast: false
145-
matrix:
146-
base-tag:
147-
- 4.11-php8.1-alpine
148-
- 4.11-php8.0-alpine
83+
php-tag:
84+
- php8.1-cli-alpine3.15
85+
- php8.0-cli-alpine3.15
86+
swoole:
87+
- openswoole
88+
- swoole
89+
includes:
90+
- swoole: openswoole
91+
swoole-version: "4.12.0"
92+
- swoole: openswoole
93+
swoole-version: "4.11.1"
94+
- swoole: swoole
95+
swoole-version: "4.8.9"
96+
- swoole: swoole
97+
swoole-version: "5.0.1"
14998

15099
steps:
151100
- uses: actions/checkout@v3
@@ -159,8 +108,8 @@ jobs:
159108
with:
160109
images: quay.io/renokico/laravel-base
161110
tags: |
162-
type=ref,event=pr,suffix=-openswoole-${{ matrix.base-tag }}
163-
type=raw,value=openswoole-${{ github.sha }}-${{ matrix.base-tag }}
111+
type=ref,event=pr,suffix=-${{ matrix.swoole }}${{ matrix.swoole-version }}-${{ matrix.php-tag }}
112+
type=raw,value=${{ github.sha }}-${{ matrix.swoole }}${{ matrix.swoole-version }}-${{ matrix.php-tag }}
164113
labels: |
165114
quay.expires-after=7d
166115
@@ -182,13 +131,15 @@ jobs:
182131
context: .
183132
tags: ${{ steps.docker_meta.outputs.tags }}
184133
labels: ${{ steps.docker_meta.outputs.labels }}
185-
file: Dockerfile.openswoole
134+
file: Dockerfile.swoole
186135
build-args: |
187-
BASE_TAG=${{ matrix.base-tag }}
136+
SWOOLE=${{ matrix.swoole }}
137+
SWOOLE_VERSION=${{ matrix.swoole-version }}
138+
PHP_TAG=${{ matrix.php-tag }}
188139
cache-from: |
189-
type=gha,scope=openswoole
140+
type=gha,scope=swoole
190141
cache-to: |
191-
type=gha,scope=openswoole
142+
type=gha,scope=swoole
192143
platforms: |
193144
linux/amd64
194145
linux/arm64

.github/workflows/docker-latest-tag.yaml

Lines changed: 24 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -64,79 +64,31 @@ jobs:
6464
linux/arm64
6565
linux/arm/v7
6666
67-
push_octane:
67+
push_swoole:
6868
if: "!contains(github.event.head_commit.message, 'skip ci')"
6969

7070
runs-on: ubuntu-latest
7171

72-
name: Tag Latest (Octane, ${{ matrix.base-tag }})
72+
name: Tag Latest (${{ matrix.swoole }}/v${{ matrix.swoole-version }} with ${{ matrix.php-tag }})
7373

7474
strategy:
7575
fail-fast: false
7676
matrix:
77-
base-tag:
78-
- 5.0-php8.1-alpine
79-
- 5.0-php8.0-alpine
80-
- 4.8-php8.1-alpine
81-
- 4.8-php8.0-alpine
82-
83-
steps:
84-
- uses: actions/checkout@v3
85-
86-
- name: Set up QEMU
87-
uses: docker/setup-qemu-action@v2
88-
89-
- name: Docker meta
90-
id: docker_meta
91-
uses: docker/metadata-action@v4.0.1
92-
with:
93-
images: quay.io/renokico/laravel-base
94-
tags: |
95-
type=raw,value=octane-latest-${{ matrix.base-tag }}
96-
97-
- name: Set up Docker Buildx
98-
uses: docker/setup-buildx-action@v2
99-
100-
- name: Login to Quay
101-
uses: docker/login-action@v2
102-
with:
103-
registry: quay.io
104-
username: ${{ secrets.DOCKER_REPOSITORY_USERNAME }}
105-
password: ${{ secrets.DOCKER_REPOSITORY_TOKEN }}
106-
107-
- name: Build and push
108-
id: docker
109-
uses: docker/build-push-action@v3
110-
with:
111-
push: true
112-
context: .
113-
tags: ${{ steps.docker_meta.outputs.tags }}
114-
labels: ${{ steps.docker_meta.outputs.labels }}
115-
file: Dockerfile.octane
116-
build-args: |
117-
BASE_TAG=${{ matrix.base-tag }}
118-
cache-from: |
119-
type=gha,scope=octane
120-
cache-to: |
121-
type=gha,scope=octane
122-
platforms: |
123-
linux/amd64
124-
linux/arm64
125-
linux/arm/v7
126-
127-
push_openswoole:
128-
if: "!contains(github.event.head_commit.message, 'skip ci')"
129-
130-
runs-on: ubuntu-latest
131-
132-
name: Tag Latest (Open Swoole for Octane, ${{ matrix.base-tag }})
133-
134-
strategy:
135-
fail-fast: false
136-
matrix:
137-
base-tag:
138-
- 4.11-php8.1-alpine
139-
- 4.11-php8.0-alpine
77+
php-tag:
78+
- php8.1-cli-alpine3.15
79+
- php8.0-cli-alpine3.15
80+
swoole:
81+
- openswoole
82+
- swoole
83+
includes:
84+
- swoole: openswoole
85+
swoole-version: "4.12.0"
86+
- swoole: openswoole
87+
swoole-version: "4.11.1"
88+
- swoole: swoole
89+
swoole-version: "4.8.9"
90+
- swoole: swoole
91+
swoole-version: "5.0.1"
14092

14193
steps:
14294
- uses: actions/checkout@v3
@@ -150,7 +102,7 @@ jobs:
150102
with:
151103
images: quay.io/renokico/laravel-base
152104
tags: |
153-
type=raw,value=openswoole-latest-${{ matrix.base-tag }}
105+
type=raw,value=latest-${{ matrix.swoole }}${{ matrix.swoole-version }}-${{ matrix.php-tag }}
154106
155107
- name: Set up Docker Buildx
156108
uses: docker/setup-buildx-action@v2
@@ -170,13 +122,15 @@ jobs:
170122
context: .
171123
tags: ${{ steps.docker_meta.outputs.tags }}
172124
labels: ${{ steps.docker_meta.outputs.labels }}
173-
file: Dockerfile.openswoole
125+
file: Dockerfile.swoole
174126
build-args: |
175-
BASE_TAG=${{ matrix.base-tag }}
127+
SWOOLE=${{ matrix.swoole }}
128+
SWOOLE_VERSION=${{ matrix.swoole-version }}
129+
PHP_TAG=${{ matrix.php-tag }}
176130
cache-from: |
177-
type=gha,scope=openswoole
131+
type=gha,scope=swoole
178132
cache-to: |
179-
type=gha,scope=openswoole
133+
type=gha,scope=swoole
180134
platforms: |
181135
linux/amd64
182136
linux/arm64

.github/workflows/docker-release-tag.yaml

Lines changed: 25 additions & 71 deletions
Original file line numberDiff line numberDiff line change
@@ -65,20 +65,30 @@ jobs:
6565
linux/arm64
6666
linux/arm/v7
6767
68-
push_octane:
68+
push_swoole:
6969
if: "!contains(github.event.head_commit.message, 'skip ci')"
7070

7171
runs-on: ubuntu-latest
7272

73-
name: Tag Release (Octane, ${{ matrix.base-tag }})
73+
name: Tag Release (${{ matrix.swoole }}/v${{ matrix.swoole-version }} with ${{ matrix.php-tag }})
7474

7575
strategy:
7676
matrix:
77-
base-tag:
78-
- 5.0-php8.1-alpine
79-
- 5.0-php8.0-alpine
80-
- 4.8-php8.1-alpine
81-
- 4.8-php8.0-alpine
77+
php-tag:
78+
- php8.1-cli-alpine3.15
79+
- php8.0-cli-alpine3.15
80+
swoole:
81+
- openswoole
82+
- swoole
83+
includes:
84+
- swoole: openswoole
85+
swoole-version: "4.12.0"
86+
- swoole: openswoole
87+
swoole-version: "4.11.1"
88+
- swoole: swoole
89+
swoole-version: "4.8.9"
90+
- swoole: swoole
91+
swoole-version: "5.0.1"
8292

8393
steps:
8494
- uses: actions/checkout@v3
@@ -89,8 +99,8 @@ jobs:
8999
with:
90100
images: quay.io/renokico/laravel-base
91101
tags: |
92-
type=semver,pattern=octane-{{version}}-${{ matrix.base-tag }}
93-
type=semver,pattern=octane-{{major}}.{{minor}}-${{ matrix.base-tag }}
102+
type=semver,pattern={{version}}-${{ matrix.swoole }}${{ matrix.swoole-version }}-${{ matrix.php-tag }}
103+
type=semver,pattern={{major}}.{{minor}}-${{ matrix.swoole }}${{ matrix.swoole-version }}-${{ matrix.php-tag }}
94104
95105
- name: Set up QEMU
96106
uses: docker/setup-qemu-action@v2
@@ -113,71 +123,15 @@ jobs:
113123
context: .
114124
tags: ${{ steps.docker_meta.outputs.tags }}
115125
labels: ${{ steps.docker_meta.outputs.labels }}
116-
file: Dockerfile.octane
126+
file: Dockerfile.swoole
117127
build-args: |
118-
BASE_TAG=${{ matrix.base-tag }}
119-
cache-from: |
120-
type=gha,scope=octane
121-
cache-to: |
122-
type=gha,scope=octane
123-
platforms: |
124-
linux/amd64
125-
linux/arm64
126-
linux/arm/v7
127-
128-
push_openswoole:
129-
if: "!contains(github.event.head_commit.message, 'skip ci')"
130-
131-
runs-on: ubuntu-latest
132-
133-
name: Tag Release (Open Swoole for Octane, ${{ matrix.base-tag }})
134-
135-
strategy:
136-
matrix:
137-
base-tag:
138-
- 4.11-php8.1-alpine
139-
- 4.11-php8.0-alpine
140-
141-
steps:
142-
- uses: actions/checkout@v3
143-
144-
- name: Docker meta
145-
id: docker_meta
146-
uses: docker/metadata-action@v4.0.1
147-
with:
148-
images: quay.io/renokico/laravel-base
149-
tags: |
150-
type=semver,pattern=openswoole-{{version}}-${{ matrix.base-tag }}
151-
type=semver,pattern=openswoole-{{major}}.{{minor}}-${{ matrix.base-tag }}
152-
153-
- name: Set up QEMU
154-
uses: docker/setup-qemu-action@v2
155-
156-
- name: Set up Docker Buildx
157-
uses: docker/setup-buildx-action@v2
158-
159-
- name: Login to Quay
160-
uses: docker/login-action@v2
161-
with:
162-
registry: quay.io
163-
username: ${{ secrets.DOCKER_REPOSITORY_USERNAME }}
164-
password: ${{ secrets.DOCKER_REPOSITORY_TOKEN }}
165-
166-
- name: Build and Push
167-
id: docker
168-
uses: docker/build-push-action@v3
169-
with:
170-
push: true
171-
context: .
172-
tags: ${{ steps.docker_meta.outputs.tags }}
173-
labels: ${{ steps.docker_meta.outputs.labels }}
174-
file: Dockerfile.openswoole
175-
build-args: |
176-
BASE_TAG=${{ matrix.base-tag }}
128+
SWOOLE=${{ matrix.swoole }}
129+
SWOOLE_VERSION=${{ matrix.swoole-version }}
130+
PHP_TAG=${{ matrix.php-tag }}
177131
cache-from: |
178-
type=gha,scope=openswoole
132+
type=gha,scope=swoole
179133
cache-to: |
180-
type=gha,scope=openswoole
134+
type=gha,scope=swoole
181135
platforms: |
182136
linux/amd64
183137
linux/arm64

0 commit comments

Comments
 (0)