-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathDockerfile
More file actions
36 lines (26 loc) · 1 KB
/
Dockerfile
File metadata and controls
36 lines (26 loc) · 1 KB
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
FROM registry.redhat.io/rhel9/rhel-bootc:9.5
ARG ORG_ID
ARG ACTIVATION_KEY
ENV ORG_ID=$ORG_ID
ENV ACTIVATION_KEY=$ACTIVATION_KEY
RUN subscription-manager register --org=${ORG_ID} --activationkey=${ACTIVATION_KEY}
RUN dnf -y install cloud-init && \
ln -s ../cloud-init.target /usr/lib/systemd/system/default.target.wants && \
rm -rf /var/{cache,log} /var/lib/{dnf,rhsm}
ADD ./wheel-nopasswd /etc/sudoers.d/
RUN dnf install -y gcc gcc-c++ make git python3.11 python3.11-devel python3-pip
USER root
ENV VIRTUAL_ENV=/opt/venv
RUN python3.11 -m venv $VIRTUAL_ENV
ENV PATH="$VIRTUAL_ENV/bin:$PATH"
RUN pip install instructlab && \
pip install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cpu && \
pip install hf_transfer
#RUN mkdir -p /usr/lib/bootc/install
#RUN cat <<EOF >> /usr/lib/bootc/install/00-kargs.toml
#[install.filesystem.root]
#type = "ext4"
#[install]
#kargs = [ "console=ttyS0", "selinux=0", "enforcing=0", "audit=0"]
#match-architectures = ["x86_64"]
#EOF