forked from protocolbuffers/protobuf
-
Notifications
You must be signed in to change notification settings - Fork 0
76 lines (68 loc) · 2.43 KB
/
test_php_ext.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
66
67
68
69
70
71
72
73
74
75
76
name: PHP Extension Tests
on:
workflow_call:
inputs:
continuous-run:
required: true
description: "Boolean string denoting whether this run is continuous --
empty string for presubmit, non-empty string for continuous."
type: string
safe-checkout:
required: true
description: "The SHA key for the commit we want to run over"
type: string
continuous-prefix:
required: true
description: "The string continuous-only tests should be prefixed with when displaying test
results."
type: string
permissions:
contents: read # to fetch code (actions/checkout)
jobs:
package:
name: Package
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: protocolbuffers/protobuf-ci/checkout@v3
with:
ref: ${{ inputs.safe-checkout }}
- name: Package extension
uses: protocolbuffers/protobuf-ci/bazel@v3
with:
credentials: ${{ secrets.GAR_SERVICE_ACCOUNT }}
bazel-cache: php_ext/${{ matrix.version }}
bash: >
./regenerate_stale_files.sh $BAZEL_FLAGS;
bazel build //php:release $BAZEL_FLAGS;
cp bazel-bin/php/protobuf-*.tgz .
- uses: actions/upload-artifact@0b7f8abb1508181956e8e162db84b466c27e18ce
with:
name: protobuf-php-release
path: protobuf-*.tgz
build:
needs: [package]
strategy:
fail-fast: false # Don't cancel all jobs if one fails.
matrix:
include:
- version: "8.1"
continuous-only: true
- version: "8.2"
continuous-only: true
- version: "8.3"
name: ${{ matrix.continuous-only && inputs.continuous-prefix || '' }} Build ${{ matrix.version }}
runs-on: ubuntu-latest
steps:
- uses: actions/download-artifact@9bc31d5ccc31df68ecc42ccf4149144866c47d8a
if: ${{ !matrix.continuous-only || inputs.continuous-run }}
with:
name: protobuf-php-release
- name: Run tests
if: ${{ !matrix.continuous-only || inputs.continuous-run }}
uses: protocolbuffers/protobuf-ci/docker@v3
with:
image: us-docker.pkg.dev/protobuf-build/containers/test/linux/php-extension:${{ matrix.version }}-a48f26c08d9a803dd0177dda63563f6ea6f7b2d4
credentials: ${{ secrets.GAR_SERVICE_ACCOUNT }}
skip-staleness-check: true
command: protobuf-*.tgz