mirror of
https://github.com/commaai/agnos-builder.git
synced 2026-06-08 02:54:40 +08:00
move a bunch of stuff into userspace/root/
This commit is contained in:
@@ -85,7 +85,11 @@ COPY ./userspace/root/etc/ /etc/
|
||||
COPY ./userspace/root/lib/ /usr/lib/
|
||||
COPY ./userspace/root/sbin/ /usr/sbin/
|
||||
COPY ./userspace/root/system/ /system/
|
||||
COPY ./userspace/root/usr/ /usr/
|
||||
COPY ./userspace/root/usr/bin/ /usr/bin/
|
||||
COPY ./userspace/root/usr/lib/ /usr/lib/
|
||||
COPY ./userspace/root/usr/lib64/ /usr/lib64/
|
||||
COPY ./userspace/root/usr/local/ /usr/local/
|
||||
COPY ./userspace/root/usr/sbin/ /usr/sbin/
|
||||
RUN mkdir -p /dsp /firmware /persist /data /cache /rwtmp
|
||||
|
||||
COPY --from=agnos-compiler-libqmi /tmp/libqmi.deb /tmp/
|
||||
@@ -124,8 +128,8 @@ RUN source $XDG_DATA_HOME/venv/bin/activate && \
|
||||
COPY ./userspace/install_extras.sh /tmp/agnos/
|
||||
RUN /tmp/agnos/install_extras.sh
|
||||
|
||||
COPY ./userspace/home/ /home/$USERNAME/
|
||||
COPY ./userspace/home/.config/ /root/.config
|
||||
COPY ./userspace/root/home/comma/ /home/$USERNAME/
|
||||
COPY ./userspace/root/home/comma/.config/ /root/.config
|
||||
RUN chown -R $USERNAME: /home/$USERNAME/.config
|
||||
|
||||
# populate /lib
|
||||
@@ -135,7 +139,6 @@ COPY ./userspace/files/*.service /lib/systemd/system/
|
||||
COPY ./userspace/files/*.timer /lib/systemd/system/
|
||||
COPY ./userspace/files/serial-getty@ttyMSM0_override.conf /lib/systemd/system/serial-getty@ttyMSM0.service.d/serial-getty@ttyMSM0_override.conf
|
||||
COPY ./userspace/files/ssh_override.conf /lib/systemd/system/ssh.service.d/override.conf
|
||||
COPY ./userspace/firmware/* /lib/firmware/
|
||||
|
||||
# populate /etc
|
||||
COPY ./userspace/files/fstab /etc
|
||||
@@ -149,8 +152,8 @@ RUN chmod 644 /etc/logrotate.conf
|
||||
RUN touch -r /lib/systemd/systemd /etc/fstab
|
||||
|
||||
# populate /usr
|
||||
COPY ./userspace/usr/comma/ /usr/$USERNAME/
|
||||
COPY ./userspace/usr/share/fonts/* /usr/share/fonts/
|
||||
COPY ./userspace/root/usr/comma/ /usr/$USERNAME/
|
||||
COPY ./userspace/root/usr/share/fonts/* /usr/share/fonts/
|
||||
COPY ./userspace/libs/* /usr/lib/aarch64-linux-gnu/
|
||||
COPY ./output/linux-headers/include/ /usr/include/
|
||||
|
||||
@@ -164,7 +167,7 @@ RUN /tmp/agnos/services.sh
|
||||
|
||||
# MOTD
|
||||
RUN rm -r /etc/update-motd.d/*
|
||||
COPY --chown=root:root ./userspace/motd/* /etc/update-motd.d/
|
||||
COPY --chown=root:root ./userspace/root/etc/update-motd.d/* /etc/update-motd.d/
|
||||
|
||||
# Let NetworkManager manage eth0
|
||||
COPY ./userspace/files/10-globally-managed-devices.conf /etc/NetworkManager/conf.d/10-globally-managed-devices.conf
|
||||
@@ -189,9 +192,6 @@ COPY ./userspace/files/avahi-override.conf /etc/systemd/system/avahi-daemon.serv
|
||||
# Prevent polkitd memory leak from getting out of hand by restarting it every ~day
|
||||
COPY ./userspace/files/polkit-override.conf /etc/systemd/system/polkit.service.d/override.conf
|
||||
|
||||
# Add iptable rules to block incoming traffic on wwan0
|
||||
COPY ./userspace/etc/iptables/rules.v4 /etc/iptables/rules.v4
|
||||
|
||||
# Run ModemManager in debug mode to allow AT commands
|
||||
COPY ./userspace/files/ModemManager.service /lib/systemd/system/
|
||||
RUN systemctl enable ModemManager
|
||||
|
||||
@@ -32,9 +32,9 @@ git submodule update --init agnos-kernel-sdm845
|
||||
|
||||
```
|
||||
cd /path/to/openpilot
|
||||
python release/pack.py -o /path/to/agnos-builder/userspace/usr/comma/setup openpilot.system.ui.mici_setup
|
||||
python release/pack.py -o /path/to/agnos-builder/userspace/usr/comma/reset openpilot.system.ui.reset
|
||||
python release/pack.py -o /path/to/agnos-builder/userspace/usr/comma/updater openpilot.system.ui.updater
|
||||
python release/pack.py -o /path/to/agnos-builder/userspace/root/usr/comma/setup openpilot.system.ui.mici_setup
|
||||
python release/pack.py -o /path/to/agnos-builder/userspace/root/usr/comma/reset openpilot.system.ui.reset
|
||||
python release/pack.py -o /path/to/agnos-builder/userspace/root/usr/comma/updater openpilot.system.ui.updater
|
||||
```
|
||||
|
||||
3. Build the kernel and system images:
|
||||
|
||||
@@ -14,7 +14,7 @@ sudo resize2fs $(findmnt -n -o SOURCE /)
|
||||
|
||||
echo "symlink /usr/comma"
|
||||
sudo rm -rf /usr/comma
|
||||
sudo ln -snf $ROOT/userspace/usr/comma/ /usr/comma
|
||||
sudo ln -snf $ROOT/userspace/root/usr/comma/ /usr/comma
|
||||
|
||||
echo "cp systemd services"
|
||||
for s in $(ls $ROOT/userspace/files/*.service); do
|
||||
|
||||
12
userspace/.gitattributes
vendored
12
userspace/.gitattributes
vendored
@@ -1,6 +1,6 @@
|
||||
usr/comma/wlan.ko filter=lfs diff=lfs merge=lfs -text
|
||||
usr/comma/wifi filter=lfs diff=lfs merge=lfs -text
|
||||
usr/comma/reset filter=lfs diff=lfs merge=lfs -text
|
||||
usr/comma/setup filter=lfs diff=lfs merge=lfs -text
|
||||
usr/comma/installer filter=lfs diff=lfs merge=lfs -text
|
||||
usr/comma/updater filter=lfs diff=lfs merge=lfs -text
|
||||
root/usr/comma/wlan.ko filter=lfs diff=lfs merge=lfs -text
|
||||
root/usr/comma/wifi filter=lfs diff=lfs merge=lfs -text
|
||||
root/usr/comma/reset filter=lfs diff=lfs merge=lfs -text
|
||||
root/usr/comma/setup filter=lfs diff=lfs merge=lfs -text
|
||||
root/usr/comma/installer filter=lfs diff=lfs merge=lfs -text
|
||||
root/usr/comma/updater filter=lfs diff=lfs merge=lfs -text
|
||||
|
||||
|
Before Width: | Height: | Size: 41 KiB After Width: | Height: | Size: 41 KiB |
Reference in New Issue
Block a user