-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathDockerfile
More file actions
37 lines (28 loc) · 1.67 KB
/
Copy pathDockerfile
File metadata and controls
37 lines (28 loc) · 1.67 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
36
37
FROM fedora:latest
# 安装 rootfs 构建工具
RUN dnf install -y \
dnf \
dnf-plugins-core \
e2fsprogs \
util-linux \
zstd \
wget \
tar \
&& dnf clean all
# 配置 openEuler-24.03-LTS-SP3 RVA20 软件源
RUN printf '[openEuler-24.03-LTS-SP3-RVA20]\nname=openEuler 24.03 LTS SP3 RVA20\nbaseurl=https://fast-mirror.isrc.ac.cn/openeuler/openEuler-24.03-LTS-SP3/everything/riscv64/rva20/riscv64/\nenabled=1\ngpgcheck=0\n' > /etc/yum.repos.d/openEuler-24.03-LTS-SP3-RVA20.repo
# 配置 openEuler-24.03-LTS-SP3 RVA23 软件源
RUN printf '[openEuler-24.03-LTS-SP3-RVA23]\nname=openEuler 24.03 LTS SP3 RVA23\nbaseurl=https://fast-mirror.isrc.ac.cn/openeuler/openEuler-24.03-LTS-SP3/everything/riscv64/rva23/riscv64/\nenabled=1\ngpgcheck=0\n' > /etc/yum.repos.d/openEuler-24.03-LTS-SP3-RVA23.repo
# 配置 openEuler-24.03-LTS-SP2 软件源
RUN printf '[openEuler-24.03-LTS-SP2]\nname=openEuler 24.03 LTS SP2\nbaseurl=https://fast-mirror.isrc.ac.cn/openeuler/openEuler-24.03-LTS-SP2/everything/riscv64/\nenabled=1\ngpgcheck=0\n' > /etc/yum.repos.d/openEuler-24.03-LTS-SP2.repo
# 配置 openRuyi RVA23 软件源
RUN printf '[openruyi-rva23]\nname=openRuyi RVA23\nbaseurl=https://boat.openruyi.cn/unstable/rva23\nenabled=1\ngpgcheck=0\n' > /etc/yum.repos.d/openruyi-rva23.repo
# 配置 openRuyi RVA20 软件源
RUN printf '[openruyi-rva20]\nname=openRuyi RVA20\nbaseurl=https://boat.openruyi.cn/unstable/rva20\nenabled=1\ngpgcheck=0\n' > /etc/yum.repos.d/openruyi-rva20.repo
# 刷新仓库缓存
RUN dnf makecache
COPY config.sh /workspace/
COPY build-rootfs.sh /workspace/
RUN chmod +x /workspace/build-rootfs.sh
WORKDIR /workspace
CMD ["/bin/bash"]