Skip to content

Commit 756ed51

Browse files
authored
refactor: new apisix ingress controller (#2421)
Signed-off-by: ashing <[email protected]>
1 parent 019d719 commit 756ed51

File tree

741 files changed

+48331
-118446
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

741 files changed

+48331
-118446
lines changed

.gitattributes

Lines changed: 0 additions & 3 deletions
This file was deleted.
Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
18+
name: APISIX Conformance Test
19+
20+
on:
21+
push:
22+
branches:
23+
- master
24+
- next
25+
pull_request:
26+
branches:
27+
- master
28+
- next
29+
30+
concurrency:
31+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
32+
cancel-in-progress: true
33+
34+
jobs:
35+
prepare:
36+
name: Prepare
37+
runs-on: ubuntu-latest
38+
steps:
39+
- name: Checkout
40+
uses: actions/checkout@v4
41+
42+
- name: Setup Go Env
43+
id: go
44+
uses: actions/setup-go@v4
45+
with:
46+
go-version: "1.23"
47+
48+
- name: Install kind
49+
run: |
50+
go install sigs.k8s.io/[email protected]
51+
52+
conformance-test:
53+
timeout-minutes: 60
54+
needs:
55+
- prepare
56+
runs-on: ubuntu-latest
57+
steps:
58+
- name: Checkout
59+
uses: actions/checkout@v4
60+
with:
61+
submodules: recursive
62+
63+
- name: Setup Go Env
64+
uses: actions/setup-go@v4
65+
with:
66+
go-version: "1.23"
67+
68+
- name: Build images
69+
env:
70+
TAG: dev
71+
ARCH: amd64
72+
ENABLE_PROXY: "false"
73+
BASE_IMAGE_TAG: "debug"
74+
ADC_VERSION: "dev"
75+
run: |
76+
echo "building images..."
77+
make build-image
78+
79+
- name: Launch Kind Cluster
80+
run: |
81+
make kind-up
82+
83+
- name: Install And Run Cloud Provider KIND
84+
run: |
85+
go install sigs.k8s.io/cloud-provider-kind@latest
86+
nohup cloud-provider-kind > /tmp/kind-loadbalancer.log 2>&1 &
87+
88+
- name: Install Gateway API And CRDs
89+
run: |
90+
make install
91+
92+
- name: Loading Docker Image to Kind Cluster
93+
run: |
94+
make kind-load-ingress-image
95+
96+
- name: Run Conformance Test
97+
shell: bash
98+
continue-on-error: true
99+
run: |
100+
make conformance-test-standalone
101+
102+
- name: Get Logs from apisix-ingress-controller
103+
shell: bash
104+
run: |
105+
export KUBECONFIG=/tmp/apisix-ingress-cluster.kubeconfig
106+
kubectl logs -n apisix-conformance-test -l app=apisix-ingress-controller
107+
108+
- name: Upload Gateway API Conformance Report
109+
if: ${{ github.event_name == 'push' }}
110+
uses: actions/upload-artifact@v4
111+
with:
112+
name: apisix-ingress-controller-conformance-report.yaml
113+
path: apisix-ingress-controller-conformance-report.yaml
114+
115+
- name: Format Conformance Test Report
116+
if: ${{ github.event_name == 'pull_request' }}
117+
run: |
118+
echo '# conformance test report' > report.md
119+
echo '```yaml' >> report.md
120+
cat apisix-ingress-controller-conformance-report.yaml >> report.md
121+
echo '```' >> report.md
Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
18+
name: APISIX E2E Test
19+
20+
on:
21+
push:
22+
branches:
23+
- master
24+
- next
25+
pull_request:
26+
branches:
27+
- master
28+
- next
29+
30+
concurrency:
31+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
32+
cancel-in-progress: true
33+
34+
jobs:
35+
prepare:
36+
name: Prepare
37+
runs-on: ubuntu-latest
38+
steps:
39+
- name: Checkout
40+
uses: actions/checkout@v4
41+
42+
- name: Setup Go Env
43+
id: go
44+
uses: actions/setup-go@v4
45+
with:
46+
go-version: "1.23"
47+
48+
- name: Install kind
49+
run: |
50+
go install sigs.k8s.io/[email protected]
51+
52+
e2e-test:
53+
needs:
54+
- prepare
55+
runs-on: ubuntu-latest
56+
steps:
57+
- name: Checkout
58+
uses: actions/checkout@v4
59+
with:
60+
submodules: recursive
61+
62+
- name: Setup Go Env
63+
uses: actions/setup-go@v4
64+
with:
65+
go-version: "1.23"
66+
67+
- name: Build images
68+
env:
69+
TAG: dev
70+
ARCH: amd64
71+
ENABLE_PROXY: "false"
72+
BASE_IMAGE_TAG: "debug"
73+
ADC_VERSION: "dev"
74+
run: |
75+
echo "building images..."
76+
make build-image
77+
78+
- name: Extract adc binary
79+
run: |
80+
echo "Extracting adc binary..."
81+
docker create --name adc-temp apache/apisix-ingress-controller:dev
82+
docker cp adc-temp:/bin/adc /usr/local/bin/adc
83+
docker rm adc-temp
84+
chmod +x /usr/local/bin/adc
85+
echo "ADC binary extracted to /usr/local/bin/adc"
86+
87+
- name: Launch Kind Cluster
88+
run: |
89+
make kind-up
90+
91+
- name: Loading Docker Image to Kind Cluster
92+
run: |
93+
make kind-load-ingress-image
94+
95+
- name: Install Gateway API And CRDs
96+
run: |
97+
make install
98+
99+
- name: Run E2E test suite
100+
shell: bash
101+
env:
102+
TEST_DIR: "./test/e2e/apisix/"
103+
run: |
104+
make e2e-test

.github/workflows/codeql-analysis.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@ on:
2424
pull_request:
2525
branches:
2626
- master
27+
- next
2728
- 1.8.0
2829
schedule:
2930
- cron: '25 5 * * 5'

.github/workflows/dependency-review.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,7 @@ on:
2121
pull_request:
2222
branches:
2323
- master
24+
- next
2425
- 1.8.0
2526

2627
permissions:

0 commit comments

Comments
 (0)