Reduce image size and attack surface
~ $ apk list
WARNING: opening from cache https://dl-cdn.alpinelinux.org/alpine/v3.19/main: No such file or directory
WARNING: opening from cache https://dl-cdn.alpinelinux.org/alpine/v3.19/community: No such file or directory
alpine-baselayout-3.4.3-r2 x86_64 {alpine-baselayout} (GPL-2.0-only) [installed]
alpine-baselayout-data-3.4.3-r2 x86_64 {alpine-baselayout} (GPL-2.0-only) [installed]
alpine-keys-2.4-r1 x86_64 {alpine-keys} (MIT) [installed]
apk-tools-2.14.0-r5 x86_64 {apk-tools} (GPL-2.0-only) [installed]
brotli-libs-1.1.0-r1 x86_64 {brotli} (MIT) [installed]
busybox-1.36.1-r15 x86_64 {busybox} (GPL-2.0-only) [installed]
busybox-binsh-1.36.1-r15 x86_64 {busybox} (GPL-2.0-only) [installed]
c-ares-1.27.0-r0 x86_64 {c-ares} (MIT) [installed]
ca-certificates-20240226-r0 x86_64 {ca-certificates} (MPL-2.0 AND MIT) [installed]
ca-certificates-bundle-20230506-r0 x86_64 {ca-certificates} (MPL-2.0 AND MIT) [installed]
cosign-2.2.1-r3 x86_64 {cosign} (Apache-2.0) [installed]
curl-8.5.0-r0 x86_64 {curl} (curl) [installed]
gcompat-1.1.0-r4 x86_64 {gcompat} (NCSA) [installed]
gdbm-1.23-r1 x86_64 {gdbm} (GPL-3.0-or-later) [installed]
git-2.43.0-r0 x86_64 {git} (GPL-2.0-only) [installed]
groff-1.23.0-r2 x86_64 {groff} (GPL-3.0-or-later) [installed]
idn2-utils-2.3.4-r4 x86_64 {libidn2} (GPL-3.0-or-later) [installed]
jq-1.7.1-r0 x86_64 {jq} (MIT) [installed]
less-643-r2 x86_64 {less} (GPL-3.0-or-later OR BSD-2-Clause) [installed]
libbz2-1.0.8-r6 x86_64 {bzip2} (bzip2-1.0.6) [installed]
libc-utils-0.7.2-r5 x86_64 {libc-dev} (BSD-2-Clause AND BSD-3-Clause) [installed]
libcrypto3-3.1.5-r0 x86_64 {openssl} (Apache-2.0) [installed]
libcurl-8.5.0-r0 x86_64 {curl} (curl) [installed]
libedit-20230828.3.1-r3 x86_64 {libedit} (BSD-3-Clause) [installed]
libexpat-2.6.2-r0 x86_64 {expat} (MIT) [installed]
libffi-3.4.4-r3 x86_64 {libffi} (MIT) [installed]
libgcc-13.2.1_git20231014-r0 x86_64 {gcc} (GPL-2.0-or-later AND LGPL-2.1-or-later) [installed]
libidn2-2.3.4-r4 x86_64 {libidn2} (GPL-2.0-or-later OR LGPL-3.0-or-later) [installed]
libncursesw-6.4_p20231125-r0 x86_64 {ncurses} (X11) [installed]
libpanelw-6.4_p20231125-r0 x86_64 {ncurses} (X11) [installed]
libssl3-3.1.5-r0 x86_64 {openssl} (Apache-2.0) [installed]
libstdc++-13.2.1_git20231014-r0 x86_64 {gcc} (GPL-2.0-or-later AND LGPL-2.1-or-later) [installed]
libucontext-1.2-r2 x86_64 {libucontext} (ISC) [installed]
libunistring-1.1-r2 x86_64 {libunistring} (GPL-2.0-or-later OR LGPL-3.0-or-later) [installed]
mpdecimal-2.5.1-r2 x86_64 {mpdecimal} (BSD-2-Clause) [installed]
musl-1.2.4_git20230717-r4 x86_64 {musl} (MIT) [installed]
musl-obstack-1.2.3-r2 x86_64 {musl-obstack} (GPL-2.0-or-later) [installed]
musl-utils-1.2.4_git20230717-r4 x86_64 {musl} (MIT AND BSD-2-Clause AND GPL-2.0-or-later) [installed]
ncurses-terminfo-base-6.4_p20231125-r0 x86_64 {ncurses} (X11) [installed]
nghttp2-libs-1.58.0-r0 x86_64 {nghttp2} (MIT) [installed]
oniguruma-6.9.9-r0 x86_64 {oniguruma} (BSD-2-Clause) [installed]
openssh-9.6_p1-r0 x86_64 {openssh} (SSH-OpenSSH) [installed]
openssh-client-common-9.6_p1-r0 x86_64 {openssh} (SSH-OpenSSH) [installed]
openssh-client-default-9.6_p1-r0 x86_64 {openssh} (SSH-OpenSSH) [installed]
openssh-keygen-9.6_p1-r0 x86_64 {openssh} (SSH-OpenSSH) [installed]
openssh-server-9.6_p1-r0 x86_64 {openssh} (SSH-OpenSSH) [installed]
openssh-server-common-9.6_p1-r0 x86_64 {openssh} (SSH-OpenSSH) [installed]
openssh-sftp-server-9.6_p1-r0 x86_64 {openssh} (SSH-OpenSSH) [installed]
openssl-3.1.5-r0 x86_64 {openssl} (Apache-2.0) [installed]
pcre2-10.42-r2 x86_64 {pcre2} (BSD-3-Clause) [installed]
pcsc-lite-libs-2.0.0-r2 x86_64 {pcsc-lite} (BSD-3-Clause AND BSD-2-Clause AND ISC) [installed]
perl-5.38.2-r0 x86_64 {perl} (Artistic-1.0-Perl OR GPL-1.0-or-later) [installed]
pyc-3.11.9-r0 x86_64 {python3} (PSF-2.0) [installed]
python3-3.11.9-r0 x86_64 {python3} (PSF-2.0) [installed]
python3-pyc-3.11.9-r0 x86_64 {python3} (PSF-2.0) [installed]
python3-pycache-pyc0-3.11.9-r0 x86_64 {python3} (PSF-2.0) [installed]
readline-8.2.1-r2 x86_64 {readline} (GPL-2.0-or-later) [installed]
scanelf-1.3.7-r2 x86_64 {pax-utils} (GPL-2.0-only) [installed]
sqlite-libs-3.44.2-r0 x86_64 {sqlite} (blessing) [installed]
ssl_client-1.36.1-r15 x86_64 {busybox} (GPL-2.0-only) [installed]
xz-libs-5.4.5-r0 x86_64 {xz} (GPL-2.0-or-later AND Public-Domain AND LGPL-2.1-or-later) [installed]
zlib-1.3.1-r0 x86_64 {zlib} (Zlib) [installed]
At least curl and openssh-server are questionable to me.