Skip to content

Commit

Permalink
fix hugepage issues for p4sdk container and image build
Browse files Browse the repository at this point in the history
fix hugepage issues for p4sdk container and image build

Signed-off-by: Halim, Abdul <[email protected]>
  • Loading branch information
ahalimx86 committed Apr 26, 2024
1 parent 42c1792 commit 4d49c78
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 2 deletions.
10 changes: 10 additions & 0 deletions e2e/artefacts/k8s/p4sdk-ds.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,23 @@ spec:
securityContext:
privileged: true
command: [ "/entrypoint.sh" ]
resources:
limits:
hugepages-2Mi: 1Gi
cpu: "2"
volumeMounts:
- name: host-libmodules
mountPath: /lib/modules
mountPropagation: HostToContainer
- mountPath: /dev/hugepages
name: hugepage
volumes:
- name: host-libmodules
hostPath:
path: /lib/modules
type: Directory
- name: hugepage
emptyDir:
medium: HugePages-2Mi


6 changes: 4 additions & 2 deletions p4sdk/images/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@

# SPDX-License-Identifier: Apache-2.0
# Copyright (c) 2024 Intel Corporation

Expand All @@ -19,11 +20,12 @@ RUN dnf -y install \
gettext-0.21-8.el9.aarch64 \
python3-pip-21.2.3-7.el9_3.1.noarch \
pciutils-3.7.0-5.el9.aarch64 \
libconfig-1.7.2-9.el9.aarch64 \
libnl3-3.7.0-1.el9.aarch64 \
libedit-3.1-38.20210216cvs.el9.aarch64 \
libatomic-11.4.1-2.1.el9.aarch64 \
&& dnf clean all
&& curl -L -o libconfig-1.7.2-9.el9.aarch64.rpm \
https://mirror.stream.centos.org/9-stream/BaseOS/aarch64/os/Packages/libconfig-1.7.2-9.el9.aarch64.rpm \
&& dnf -y install libconfig-1.7.2-9.el9.aarch64.rpm && rm -f libconfig-1.7.2-9.el9.aarch64.rpm && dnf clean all
RUN python3 -m pip install --no-cache-dir \
grpcio==1.62.1 \
protobuf==4.25.3 \
Expand Down

0 comments on commit 4d49c78

Please sign in to comment.