-
-
Notifications
You must be signed in to change notification settings - Fork 148
Expand file tree
/
Copy pathContainerfile.rootfs.22_04
More file actions
127 lines (113 loc) · 3.12 KB
/
Copy pathContainerfile.rootfs.22_04
File metadata and controls
127 lines (113 loc) · 3.12 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
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
FROM ubuntu:jammy
LABEL org.opencontainers.image.authors="Badr @pythops"
# Add focal main repo
RUN echo "deb http://ports.ubuntu.com/ubuntu-ports/ focal main" >> /etc/apt/sources.list && \
apt update
RUN rm /var/lib/dpkg/info/libc-bin.* && \
apt-get clean && \
apt-get update && \
apt-get install libc-bin
# Nvidia required packages
RUN apt install -y \
libgles2 \
libpangoft2-1.0-0 \
libxkbcommon0 \
libwayland-egl1 \
libwayland-cursor0 \
libunwind8 \
libasound2 \
libpixman-1-0 \
libjpeg-turbo8 \
libinput10 \
libcairo2 \
device-tree-compiler \
iso-codes \
libncursesw5 \
libdrm-common \
libdrm2 \
libegl-mesa0 \
libegl1 \
libegl1-mesa \
libgtk-3-0 \
libgstreamer1.0-0 \
libgstreamer-plugins-bad1.0-0 \
libnl-route-3-200 \
libseat1 \
efibootmgr \
busybox \
wget \
cpio \
nvme-cli \
i2c-tools \
bridge-utils \
libffi7 \
libvulkan1 \
libssl1.1 && \
apt install -y wget cpio busybox && \
wget http://launchpadlibrarian.net/354032550/libffi6_3.2.1-8_arm64.deb && \
dpkg -i libffi6_3.2.1-8_arm64.deb
# Additional tools
RUN DEBIAN_FRONTEND=noninteractive apt install -y \
systemd \
bash-completion \
build-essential \
pkg-config \
btrfs-progs \
cmake \
curl \
dnsutils \
htop \
iotop \
iputils-ping \
kmod \
linux-firmware \
locales \
net-tools \
pciutils \
python3-dev \
ssh \
sudo \
udev \
unzip \
usbutils \
neovim \
parted \
gdisk \
fdisk \
e2fsprogs \
mtd-utils \
python-is-python3 \
git \
fwupd \
iwd
# Tegratop
RUN wget -q https://github.com/pythops/tegratop/releases/latest/download/tegratop-linux-arm64 -O /usr/local/bin/tegratop && \
chmod +x /usr/local/bin/tegratop
# Impala
RUN wget -q https://github.com/pythops/impala/releases/latest/download/impala-aarch64-unknown-linux-musl -O /usr/local/bin/impala && \
chmod +x /usr/local/bin/impala
# Resize the rootfs
COPY scripts/resizerootfs.sh /usr/local/bin
COPY scripts/resizerootfs.service /lib/systemd/system
# Generate locales
RUN locale-gen en_US.UTF-8
# Enable services at startuo
RUN systemctl enable resizerootfs.service && \
systemctl enable systemd-timesyncd && \
systemctl enable iwd
# WiFi Networks config
COPY config/iwd/networks/* /var/lib/iwd/
COPY config/iwd/main.conf /etc/iwd/main.conf
# New user
# username: jetson
# password: jetson
RUN useradd \
--create-home \
-G sudo,video,audio \
-p $(openssl passwd -6 jetson) \
-s /bin/bash \
jetson
# Add /usr/local/cuda/bin to the PATH
RUN echo "if [ -d \"/usr/local/cuda/bin\" ] ; then" >> /home/jetson/.profile && \
echo " PATH=\"/usr/local/cuda/bin:\$PATH\"" >> /home/jetson/.profile && \
echo "fi" >> /home/jetson/.profile