Closed
Description
Description
Docker fails to build image from Dockerfile.
Swagger-codegen version
n/a
Swagger declaration file content or url
n/a
Command line used for generation
n/a
Steps to reproduce
docker build ./
[+] Building 0.4s (6/16)
=> [internal] load .dockerignore 0.0s
=> => transferring context: 310B 0.0s
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 1.17kB 0.0s
=> [internal] load metadata for docker.io/library/maven:3-eclipse-temurin-11 0.0s
=> CACHED [ 1/12] FROM docker.io/library/maven:3-eclipse-temurin-11 0.0s
=> [internal] load build context 0.4s
=> => transferring context: 10.87MB 0.3s
=> ERROR [ 2/12] RUN set -x && apk add --no-cache bash 0.4s
------
> [ 2/12] RUN set -x && apk add --no-cache bash:
#0 0.320 + apk add --no-cache bash
#0 0.320 /bin/sh: 1: apk: not found
------
Dockerfile:3
--------------------
2 |
3 | >>> RUN set -x && \
4 | >>> apk add --no-cache bash
5 |
--------------------
ERROR: failed to solve: process "/bin/sh -c set -x && apk add --no-cache bash" did not complete successfully: exit code: 127
Related issues/PRs
None found.
Suggest a fix/enhancement
The base image maven:3-eclipse-temurin-11 here is not alpine so apk
is not found.
Update the line with maven:3-eclipse-temurin-11-alpine
to explicitly ask for the alpine image.
Metadata
Metadata
Assignees
Labels
No labels