@@ -6,68 +6,95 @@ FROM ubuntu:24.04 AS ovs-builder
66ARG ARCH
77ARG LEGACY
88ARG DEBIAN_FRONTEND=noninteractive
9- ENV SRC_DIR='/usr/src'
9+ ARG SRC_DIR='/usr/src'
10+
11+ ADD patches/4228eab1d722087ba795e310eadc9e25c4513ec1.patch $SRC_DIR
12+ ADD patches/54056ea65dc28aa1c4c721a2a34d7913f79f8376.patch $SRC_DIR
13+ ADD patches/6b4dcb311f171d81a5d40ea51a273fc356c123db.patch $SRC_DIR
14+ ADD patches/f627b7721ec282f2edaf798913b1559b939687f0.patch $SRC_DIR
15+ ADD patches/3f3e3a436ff5eb2eaafbeeae8ea9dc0c514fe8a3.patch $SRC_DIR
16+ ADD patches/a6cb8215a80635129e4fada4c0d25c25fb746bf7.patch $SRC_DIR
17+ ADD patches/d4d76ddb2e12cdd9e73bb5e008ebb9fd1b4d6ca6.patch $SRC_DIR
18+ ADD patches/ffd2328d4a55271569e2b89e54a2c18f4e186af8.patch $SRC_DIR
19+ ADD patches/d088c5d8c263552c5a31d87813991aee30ab74de.patch $SRC_DIR
20+ ADD patches/1b31f07dc60c016153fa35d936cdda0e02e58492.patch $SRC_DIR
21+ ADD patches/54b767822916606dbb78335a3197983f435b5b8a.patch $SRC_DIR
22+ ADD patches/e490f5ac0b644101913c2a3db8e03d85e859deff.patch $SRC_DIR
23+ ADD patches/b973ec477b43df1c3ef3cdb69f8646948fcf94ae.patch $SRC_DIR
24+ ADD patches/5593e614e51a5dce28941e5bf760f9ee5397cede.patch $SRC_DIR
25+ ADD patches/f9e97031b56ab5747b5d73629198331a6daacdfd.patch $SRC_DIR
26+ ADD patches/53d961492036f1d41d9d1b04bab628375a9c6eb5.patch $SRC_DIR
27+ ADD patches/44229317de74d1e97f7499b371a86c015be6b7a6.patch $SRC_DIR
28+ ADD patches/786756870f12ac69a5d7bc498693574c6591c5e9.patch $SRC_DIR
29+ ADD patches/505dc82f54d4ce54e0378fd3bac1052ee644ac59.patch $SRC_DIR
30+ ADD patches/f4b1f5fbf0f5aff68299efaa2d0577c90cb2568e.patch $SRC_DIR
31+ ADD patches/b3af07690e7b2328c02318b1bd812c5665c0632b.patch $SRC_DIR
32+ ADD patches/49834fdd3fa3b066650bc8b7a8b05a773d217d95.patch $SRC_DIR
33+ ADD patches/03e35ed9c5b4de0fa8acbc2c057cdd5957a8d605.patch $SRC_DIR
34+ ADD patches/b5e2975eb65f37315545300254fc0f58a9df52b1.patch $SRC_DIR
35+ ADD patches/e7d3ba53cdcbc524bb29c54ddb07b83cc4258ed7.patch $SRC_DIR
36+ ADD patches/a9e009136a42cf6d985f97e2bf1ec41df6b5ca29.patch $SRC_DIR
1037
1138RUN apt update && apt install -y git curl
1239
1340RUN cd /usr/src/ && \
1441 git clone -b branch-3.3 --depth=1 https://github.com/openvswitch/ovs.git && \
1542 cd ovs && \
1643 # fix memory leak by ofport_usage and trim memory periodically
17- curl -s https://github.com/kubeovn/ovs/commit/ 4228eab1d722087ba795e310eadc9e25c4513ec1.patch | git apply && \
44+ git apply $SRC_DIR/ 4228eab1d722087ba795e310eadc9e25c4513ec1.patch && \
1845 # increase election timer
19- curl -s https://github.com/kubeovn/ovs/commit/ 54056ea65dc28aa1c4c721a2a34d7913f79f8376.patch | git apply && \
46+ git apply $SRC_DIR/ 54056ea65dc28aa1c4c721a2a34d7913f79f8376.patch && \
2047 # add fdb update logging
21- curl -s https://github.com/kubeovn/ovs/commit/ 6b4dcb311f171d81a5d40ea51a273fc356c123db.patch | git apply && \
48+ git apply $SRC_DIR/ 6b4dcb311f171d81a5d40ea51a273fc356c123db.patch && \
2249 # fdb: fix mac learning in environments with hairpin enabled
23- curl -s https://github.com/kubeovn/ovs/commit/ f627b7721ec282f2edaf798913b1559b939687f0.patch | git apply && \
50+ git apply $SRC_DIR/ f627b7721ec282f2edaf798913b1559b939687f0.patch && \
2451 # ovsdb-tool: add optional server id parameter for "join-cluster" command
25- curl -s https://github.com/kubeovn/ovs/commit/ 3f3e3a436ff5eb2eaafbeeae8ea9dc0c514fe8a3.patch | git apply && \
52+ git apply $SRC_DIR/ 3f3e3a436ff5eb2eaafbeeae8ea9dc0c514fe8a3.patch && \
2653 # fix memory leak in qos
27- curl -s https://github.com/kubeovn/ovs/commit/ a6cb8215a80635129e4fada4c0d25c25fb746bf7.patch | git apply && \
54+ git apply $SRC_DIR/ a6cb8215a80635129e4fada4c0d25c25fb746bf7.patch && \
2855 # ovsdb-tool: add command fix-cluster
29- curl -s https://github.com/kubeovn/ovs/commit/ d4d76ddb2e12cdd9e73bb5e008ebb9fd1b4d6ca6.patch | git apply && \
56+ git apply $SRC_DIR/ d4d76ddb2e12cdd9e73bb5e008ebb9fd1b4d6ca6.patch && \
3057 # netdev: reduce cpu utilization for getting device addresses
31- curl -s https://github.com/kubeovn/ovs/commit/ ffd2328d4a55271569e2b89e54a2c18f4e186af8.patch | git apply && \
58+ git apply $SRC_DIR/ ffd2328d4a55271569e2b89e54a2c18f4e186af8.patch && \
3259 # ovs-router: skip getting source address for kube-ipvs0
33- curl -s https://github.com/kubeovn/ovs/commit/ d088c5d8c263552c5a31d87813991aee30ab74de.patch | git apply && \
60+ git apply $SRC_DIR/ d088c5d8c263552c5a31d87813991aee30ab74de.patch && \
3461 # increase the default probe interval for large cluster
35- curl -s https://github.com/kubeovn/ovs/commit/ 1b31f07dc60c016153fa35d936cdda0e02e58492.patch | git apply && \
62+ git apply $SRC_DIR/ 1b31f07dc60c016153fa35d936cdda0e02e58492.patch && \
3663 # update ovs-sandbox for docker run
37- curl -s https://github.com/kubeovn/ovs/commit/ 54b767822916606dbb78335a3197983f435b5b8a.patch | git apply
64+ git apply $SRC_DIR/ 54b767822916606dbb78335a3197983f435b5b8a.patch
3865
3966RUN cd /usr/src/ && git clone -b branch-24.03 --depth=1 https://github.com/ovn-org/ovn.git && \
4067 cd ovn && \
4168 # change hash type from dp_hash to hash with field src_ip
42- curl -s https://github.com/kubeovn/ovn/commit/ e490f5ac0b644101913c2a3db8e03d85e859deff.patch | git apply && \
69+ git apply $SRC_DIR/ e490f5ac0b644101913c2a3db8e03d85e859deff.patch && \
4370 # modify src route priority
44- curl -s https://github.com/kubeovn/ovn/commit/ b973ec477b43df1c3ef3cdb69f8646948fcf94ae.patch | git apply && \
71+ git apply $SRC_DIR/ b973ec477b43df1c3ef3cdb69f8646948fcf94ae.patch && \
4572 # fix reaching resubmit limit in underlay
46- curl -s https://github.com/kubeovn/ovn/commit/ 5593e614e51a5dce28941e5bf760f9ee5397cede.patch | git apply && \
73+ git apply $SRC_DIR/ 5593e614e51a5dce28941e5bf760f9ee5397cede.patch && \
4774 # ovn-controller: do not send GARP on localnet for Kube-OVN ports
48- curl -s https://github.com/kubeovn/ovn/commit/ f9e97031b56ab5747b5d73629198331a6daacdfd.patch | git apply && \
75+ git apply $SRC_DIR/ f9e97031b56ab5747b5d73629198331a6daacdfd.patch && \
4976 # northd: add nb option version_compatibility
50- curl -s https://github.com/kubeovn/ovn/commit/ 53d961492036f1d41d9d1b04bab628375a9c6eb5.patch | git apply && \
77+ git apply $SRC_DIR/ 53d961492036f1d41d9d1b04bab628375a9c6eb5.patch && \
5178 # add support for conditionally skipping conntrack
52- curl -s https://github.com/kubeovn/ovn/commit/ 44229317de74d1e97f7499b371a86c015be6b7a6.patch | git apply && \
79+ git apply $SRC_DIR/ 44229317de74d1e97f7499b371a86c015be6b7a6.patch && \
5380 # northd: skip conntrack when access node local dns ip
54- curl -s https://github.com/kubeovn/ovn/commit/ 786756870f12ac69a5d7bc498693574c6591c5e9.patch | git apply && \
81+ git apply $SRC_DIR/ 786756870f12ac69a5d7bc498693574c6591c5e9.patch && \
5582 # lflow: do not send direct traffic between lports to conntrack
56- curl -s https://github.com/kubeovn/ovn/commit/ 505dc82f54d4ce54e0378fd3bac1052ee644ac59.patch | git apply && \
83+ git apply $SRC_DIR/ 505dc82f54d4ce54e0378fd3bac1052ee644ac59.patch && \
5784 # direct output to lsp for dnat packets in logical switch ingress pipelines
58- curl -s https://github.com/kubeovn/ovn/commit/ f4b1f5fbf0f5aff68299efaa2d0577c90cb2568e.patch | git apply && \
85+ git apply $SRC_DIR/ f4b1f5fbf0f5aff68299efaa2d0577c90cb2568e.patch && \
5986 # fix lr-lb dnat with multiple distributed gateway ports
60- curl -s https://github.com/kubeovn/ovn/commit/ b3af07690e7b2328c02318b1bd812c5665c0632b.patch | git apply && \
87+ git apply $SRC_DIR/ b3af07690e7b2328c02318b1bd812c5665c0632b.patch && \
6188 # northd: skip arp/nd request for lrp addresses from localnet ports
62- curl -s https://github.com/kubeovn/ovn/commit/ 49834fdd3fa3b066650bc8b7a8b05a773d217d95.patch | git apply && \
89+ git apply $SRC_DIR/ 49834fdd3fa3b066650bc8b7a8b05a773d217d95.patch && \
6390 # ovn-controller: make activation strategy work for single chassis
64- curl -s https://github.com/kubeovn/ovn/commit/ 03e35ed9c5b4de0fa8acbc2c057cdd5957a8d605.patch | git apply && \
91+ git apply $SRC_DIR/ 03e35ed9c5b4de0fa8acbc2c057cdd5957a8d605.patch && \
6592 # support dedicated BFD LRP
66- curl -s https://github.com/kubeovn/ovn/commit/ b5e2975eb65f37315545300254fc0f58a9df52b1.patch | git apply && \
93+ git apply $SRC_DIR/ b5e2975eb65f37315545300254fc0f58a9df52b1.patch && \
6794 # skip node local dns ip conntrack when set acl
68- curl -s https://github.com/kubeovn/ovn/commit/ e7d3ba53cdcbc524bb29c54ddb07b83cc4258ed7.patch | git apply && \
95+ git apply $SRC_DIR/ e7d3ba53cdcbc524bb29c54ddb07b83cc4258ed7.patch && \
6996 # select local backend first
70- curl -s https://github.com/kubeovn/ovn/commit/ a9e009136a42cf6d985f97e2bf1ec41df6b5ca29.patch | git apply
97+ git apply $SRC_DIR/ a9e009136a42cf6d985f97e2bf1ec41df6b5ca29.patch
7198
7299RUN apt install -y build-essential fakeroot \
73100 autoconf automake bzip2 debhelper-compat dh-exec dh-python dh-sequence-python3 dh-sequence-sphinxdoc \
@@ -117,10 +144,10 @@ RUN mkdir /packages/ && \
117144FROM ghcr.io/aquasecurity/trivy:latest AS trivy
118145
119146ARG ARCH
120- ENV CNI_PLUGINS_VERSION="v1.7.1"
121- ENV KUBECTL_VERSION="v1.32.4"
122- ENV GOBGP_VERSION="3.36.0"
123- ENV TRIVY_DB_REPOSITORY="public.ecr.aws/aquasecurity/trivy-db:2"
147+ ARG CNI_PLUGINS_VERSION="v1.7.1"
148+ ARG KUBECTL_VERSION="v1.32.4"
149+ ARG GOBGP_VERSION="3.36.0"
150+ ARG TRIVY_DB_REPOSITORY="public.ecr.aws/aquasecurity/trivy-db:2"
124151
125152RUN apk --no-cache add curl jq
126153ADD go-deps/download-go-deps.sh /
0 commit comments