Created
February 13, 2025 10:15
-
-
Save kabakaev/c313c9a55d17efe89b4f71a5131b0c0a to your computer and use it in GitHub Desktop.
openssl-3.4.1 static binary, built and linked on amazonlinux:2023
This file contains hidden or 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
| # podman build -t amazonlinux:2023-openssl-static . | |
| FROM amazonlinux:2023 as builder | |
| ARG openssl_release=https://github.com/openssl/openssl/releases/download/openssl-3.4.1/openssl-3.4.1.tar.gz | |
| RUN dnf update -y && \ | |
| dnf install -y \ | |
| curl-minimal \ | |
| gcc \ | |
| gcc-c++ \ | |
| glibc-static \ | |
| gzip \ | |
| make \ | |
| perl \ | |
| tar \ | |
| which | |
| RUN mkdir -p /root/openssl \ | |
| && curl -fsSL "${openssl_release}" \ | |
| | tar xz --strip-components=1 -C /root/openssl | |
| WORKDIR /root/openssl | |
| # https://wiki.openssl.org/index.php/Compilation_and_Installation | |
| RUN ./config \ | |
| no-shared \ | |
| no-tests \ | |
| no-weak-ssl-ciphers \ | |
| --prefix=/usr/local/ssl \ | |
| --openssldir=/usr/local/ssl \ | |
| -static \ | |
| && make -j$(nproc) \ | |
| && make install | |
| FROM amazonlinux:2023 | |
| COPY --from=builder /usr/local/ssl/bin/openssl /usr/local/bin/openssl-static | |
| # SPDX-License-Identifier: MIT |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment