docker: enable apt upgrade step

This commit is contained in:
Leonid Pliushch
2023-02-22 21:50:05 +02:00
parent f7755c0d4a
commit 5e6b4f4026

View File

@@ -54,18 +54,16 @@ RUN busybox chown -Rh 0:0 /system && \
cd /data/data/com.termux/files/usr && \ cd /data/data/com.termux/files/usr && \
busybox find ./bin ./lib/apt ./libexec -type f -exec busybox chmod 700 "{}" \; busybox find ./bin ./lib/apt ./libexec -type f -exec busybox chmod 700 "{}" \;
# Switch user to non-root.
#USER 1000:1000
# Update static DNS cache, install updates and cleanup when not building for arm. # Update static DNS cache, install updates and cleanup when not building for arm.
#ENV PATH /data/data/com.termux/files/usr/bin ENV PATH /data/data/com.termux/files/usr/bin
#RUN if [ ${BOOTSTRAP_ARCH} == 'arm' ]; then exit; else \ RUN if [ ${BOOTSTRAP_ARCH} == 'arm' ]; then exit; else \
# apt update && \ /system/bin/dnsmasq -u root -g root & sleep 1 && \
# apt upgrade -o Dpkg::Options::=--force-confnew -yq && \ su - system -c "/data/data/com.termux/files/usr/bin/apt update" && \
# rm -rf /data/data/com.termux/files/usr/var/lib/apt/* && \ su - system -c "/data/data/com.termux/files/usr/bin/apt upgrade -o Dpkg::Options::=--force-confnew -yq" && \
# rm -rf /data/data/com.termux/files/usr/var/log/apt/* && \ rm -rf /data/data/com.termux/files/usr/var/lib/apt/* && \
# rm -rf /data/data/com.termux/cache/apt/* ;\ rm -rf /data/data/com.termux/files/usr/var/log/apt/* && \
# fi rm -rf /data/data/com.termux/cache/apt/* ;\
fi
############################################################################## ##############################################################################
# Create final image. # Create final image.