You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The current way to achieve this is by leveraging build_args and modifying the Dockerfile as follows:
FROM alpine
ARG SECRET
RUN --mount=type=secret,id=$SECRET,target=/secrets/muysecret \
cat /secrets/muysecret
A possible alternative is to modify the current build step and allow sending secrets:[SecretID!] so Dockerfiles can continue to work without any changes.
Activity
shykes commentedon Jan 19, 2023
Is this the same thing as #2550 @sipsma ?
sipsma commentedon Jan 19, 2023
Yes but I'll close my older pre 0.3 one since this one has a proposal in terms of the new API
[-]Improve secrets DX for Dockerbuild[/-][+]Access secrets from a Dockerfile[/+]