This repository has been archived on 2024-08-04. You can view files and clone it, but cannot push or open issues or pull requests.
stagex/bash/Dockerfile

20 lines
697 B
Docker

ARG GCC_IMAGE=library/gcc@sha256:ca38f292fe1ad0933f0122a657f9c644ed1f0a9e1aa336abcc83d420ad487e28
FROM ${GCC_IMAGE} as build
ENV SOURCE_SITE=https://ftp.gnu.org/gnu/bash
ENV SOURCE_VERSION=5.2.15
ENV SOURCE_HASH=13720965b5f4fc3a0d4b61dd37e7565c741da9a5be24edc2ae00182fc1b3588c
RUN wget ${SOURCE_SITE}/bash-${SOURCE_VERSION}.tar.gz
RUN echo "${SOURCE_HASH} bash-${SOURCE_VERSION}.tar.gz" | sha256sum -c
RUN tar -xzf bash-${SOURCE_VERSION}.tar.gz
WORKDIR bash-${SOURCE_VERSION}
RUN set -eux; \
./configure \
--prefix=/usr \
--enable-static-link; \
make DESTDIR=/home/user/rootfs
RUN make install DESTDIR=/home/user/rootfs
FROM scratch
COPY --from=build /home/user/rootfs /