dependency_resolve

command module
v0.0.0-...-fed2d62 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 26, 2024 License: MIT Imports: 8 Imported by: 0

README

dependency_resolve - distroless packaging support

Binary packaging support tool for distroless / alpine.

Usage

FROM debian:12 AS builder
FROM --platform="${PLATFORM}" ${GOLANG} AS golang
COPY "./" "/build"
RUN cd "/build" \
 &&   go build -o "/usr/local/bin/dependency_resolve" . \
 && cd -
COPY --from=golang "/usr/local/bin/dependency_resolve" "/usr/local/bin/dependency_resolve"
RUN apt-get update && apt-get install -y "binutils" "php"
RUN /usr/local/bin/dependency_resolve "$(which "php")" | xargs -I {} sh -c 'mkdir -p /rootfs/$(dirname "{}") && cp -apP "{}" "/rootfs/{}" && (strip --strip-all "/rootfs/{}" || true)'

FROM gcr.io/distroless/base-nossl-debian12:latest
COPY --from=builder "/rootfs" "/"

ENTRYPOINT ["/usr/bin/php"]

See Dockerfile for more details.

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL