-
Notifications
You must be signed in to change notification settings - Fork 1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch '3.2' into changelog_3.2
- Loading branch information
Showing
32 changed files
with
6,299 additions
and
5,540 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,11 @@ | ||
# Exclude everything from the Docker build context: | ||
* | ||
|
||
# Except for this content: | ||
!bin/ | ||
!etc/ | ||
!testssl.sh | ||
|
||
# But additionally exclude this nested content: | ||
bin/openssl.Darwin.* | ||
bin/openssl.FreeBSD.* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
*.sh eol=lf | ||
*.bash eol=lf | ||
*.md eol=lf | ||
*.html eol=lf | ||
*.txt eol=lf | ||
*.txt eol=lf | ||
*.1 eol=lf | ||
*.t eol=lf | ||
*.yml eol=lf | ||
Dockerfile* eol=lf | ||
*.csvfile eol=lf |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -9,6 +9,7 @@ tmp.html | |
*.log | ||
*.xml | ||
*.iml | ||
*.script | ||
*.swp | ||
*.swo | ||
*~ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,40 @@ | ||
FROM alpine:3.16 | ||
# syntax=docker.io/docker/dockerfile:1 | ||
|
||
RUN apk update && \ | ||
apk upgrade && \ | ||
apk add bash procps drill git coreutils libidn curl socat openssl xxd && \ | ||
rm -rf /var/cache/apk/* && \ | ||
addgroup testssl && \ | ||
adduser -G testssl -g "testssl user" -s /bin/bash -D testssl && \ | ||
ln -s /home/testssl/testssl.sh /usr/local/bin/ && \ | ||
mkdir -m 755 -p /home/testssl/etc /home/testssl/bin | ||
ARG LEAP_VERSION=15.4 | ||
ARG INSTALL_ROOT=/rootfs | ||
|
||
USER testssl | ||
WORKDIR /home/testssl/ | ||
FROM opensuse/leap:${LEAP_VERSION} as builder | ||
ARG CACHE_ZYPPER=/tmp/cache/zypper | ||
ARG INSTALL_ROOT | ||
# /etc/os-release provides $VERSION_ID | ||
RUN source /etc/os-release \ | ||
&& export ZYPPER_OPTIONS=( --releasever "${VERSION_ID}" --installroot "${INSTALL_ROOT}" --cache-dir "${CACHE_ZYPPER}" ) \ | ||
&& zypper "${ZYPPER_OPTIONS[@]}" --gpg-auto-import-keys refresh \ | ||
&& zypper "${ZYPPER_OPTIONS[@]}" --non-interactive install --download-in-advance --no-recommends \ | ||
bash procps grep gawk sed coreutils busybox-util-linux busybox-vi ldns libidn2-0 socat openssl curl \ | ||
&& zypper "${ZYPPER_OPTIONS[@]}" clean --all | ||
## Cleanup (reclaim approx 13 MiB): | ||
# None of this content should be relevant to the container: | ||
RUN rm -r "${INSTALL_ROOT}/usr/share/"{licenses,man,locale,doc,help,info} | ||
# Functionality that the container doesn't need: | ||
RUN rm "${INSTALL_ROOT}/usr/share/misc/termcap" \ | ||
&& rm -r "${INSTALL_ROOT}/usr/lib/sysimage/rpm" | ||
|
||
COPY --chown=testssl:testssl etc/. /home/testssl/etc/ | ||
COPY --chown=testssl:testssl bin/. /home/testssl/bin/ | ||
COPY --chown=testssl:testssl testssl.sh /home/testssl/ | ||
|
||
ENTRYPOINT ["testssl.sh"] | ||
# Create a new image with the contents of $INSTALL_ROOT | ||
FROM scratch | ||
ARG INSTALL_ROOT | ||
COPY --link --from=builder ${INSTALL_ROOT} / | ||
# Link busybox to tar, see #2403. Create user + (home with SGID set): | ||
RUN ln -s /usr/bin/busybox /usr/bin/tar \ | ||
&& echo 'testssl:x:1000:1000::/home/testssl:/bin/bash' >> /etc/passwd \ | ||
&& echo 'testssl:x:1000:' >> /etc/group \ | ||
&& echo 'testssl:!::0:::::' >> /etc/shadow \ | ||
&& install --mode 2755 --owner testssl --group testssl --directory /home/testssl \ | ||
&& ln -s /home/testssl/testssl.sh /usr/local/bin/ | ||
|
||
# Copy over build context (after filtered by .dockerignore): bin/ etc/ testssl.sh | ||
COPY --chown=testssl:testssl . /home/testssl/ | ||
USER testssl | ||
ENTRYPOINT ["testssl.sh"] | ||
CMD ["--help"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
# Build using git repo | ||
|
||
FROM alpine:3.16 | ||
FROM alpine:3.17 | ||
|
||
WORKDIR /home/testssl | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.