Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dockerfile does not work #1

Open
shajalahamedcse opened this issue Jun 27, 2024 · 1 comment
Open

dockerfile does not work #1

shajalahamedcse opened this issue Jun 27, 2024 · 1 comment

Comments

@shajalahamedcse
Copy link

shajalahamedcse commented Jun 27, 2024

FROM ubuntu:24.04

WORKDIR /home/xdp_lb

RUN apt-get update 

RUN apt-get install -y clang llvm libelf-dev libbpf-dev libpcap-dev gcc-multilib build-essential make linux-tools-common

RUN apt-get install -y linux-headers-$(uname -r) linux-tools-$(uname -r) linux-headers-generic linux-tools-generic

RUN apt-get install -y curl iproute2 iputils-ping nano dwarves tcpdump bind9-dnsutils

RUN apt-get install -y jq

RUN apt-get clean

COPY ./xdp/xdp_lb.c .

COPY ./attach_xdp.sh .

RUN clang -O2 -target bpf -g -c xdp_lb.c -o xdp_lb.o

RUN chmod +x attach_xdp.sh
ENTRYPOINT [ "./attach_xdp.sh" ]
Screenshot 2567-06-27 at 10 12 23
@REZ0AN
Copy link
Owner

REZ0AN commented Jun 27, 2024

As the docker uses the host machine kernel , you have to use the Ubuntu version of the host machine, here I have used 24.04 version because my host machine has Ubuntu24.04.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants