Skip to content

Commit d7ac5c8

Browse files
committed
Make sure we actually have dpkg-architecture
It is provided by `dpkg-dev`, which is installed already in some but not all `cross` images. This commit also: - Allows more configuration to occur by installing `apt-utils`. Without this, `gnupg` warns about skipping some debconf configuration. - Sets up the environment in which commands like `apt-get` and `dpkg` run so configuring packages never prompts. Passing `-y` is not sufficient to achieve this. (The problem currently does not occur, but it would happen in at least the Android image if a new dependency brings in `tzdata` indirectly, as will occur if attempting to install dependencies to test more than `max-pure`.)
1 parent ff538fe commit d7ac5c8

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

etc/docker/Dockerfile.test-cross

+5-2
Original file line numberDiff line numberDiff line change
@@ -5,13 +5,16 @@ FROM ghcr.io/cross-rs/${TARGET}:latest
55
ARG TARGET
66

77
RUN set -uC && \
8+
export DEBIAN_FRONTEND=noninteractive TZ=UTC && \
9+
apt-get update && \
10+
apt-get install --no-install-recommends -y apt-utils && \
11+
apt-get install --no-install-recommends -y apt-transport-https dpkg-dev gnupg && \
12+
type dpkg-architecture && \
813
apt_suffix= && \
914
if target_arch="$(dpkg-architecture --host-type "$TARGET" --query DEB_HOST_ARCH)"; then \
1015
dpkg --add-architecture "$target_arch" && \
1116
apt_suffix=":$target_arch"; \
1217
fi && \
13-
apt-get update && \
14-
apt-get install --no-install-recommends -y apt-transport-https gnupg && \
1518
release="$(sed -n 's/^VERSION_CODENAME=//p' /etc/os-release)" && \
1619
echo "deb https://ppa.launchpadcontent.net/git-core/ppa/ubuntu $release main" \
1720
>/etc/apt/sources.list.d/git-core-ubuntu-ppa.list && \

0 commit comments

Comments
 (0)