-
Notifications
You must be signed in to change notification settings - Fork 16
/
Copy pathDockerfile
23 lines (18 loc) · 1.21 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# https://github.com/OpenAPITools/openapi-generator/commit/93df0ff4448384822e2488593ed7b72e13e7738e
FROM openapitools/openapi-generator-cli@sha256:67100c4bda1fb1886b5024e3a7549f905002f6393d19f828f438c902b8f85d67 AS jar
# Ensure the jar file is build
RUN /usr/local/bin/docker-entrypoint.sh version
FROM fedora:35
ENV OPENAPI_GENERATOR_VERSION=5.0.0-SNAPSHOT \
PACKAGES="docker findutils git golang-x-tools-goimports java jq maven nodejs patch python3 python3-pip unzip"
RUN dnf install -y gcc-c++ make && \
curl -sL https://rpm.nodesource.com/setup_16.x | bash - && \
dnf install -y ${PACKAGES} && \
dnf clean all && \
curl https://raw.githubusercontent.com/OpenAPITools/openapi-generator/master/bin/utils/openapi-generator-cli.sh > /usr/bin/openapi-generator && \
chmod +x /usr/bin/openapi-generator
# for manipulating html docs
RUN pip3 install beautifulsoup4
COPY --from=jar /opt/openapi-generator/modules/openapi-generator-cli/target/openapi-generator-cli.jar /usr/bin/openapi-generator-cli-${OPENAPI_GENERATOR_VERSION}.jar
# make an unversioned JAR for "templates" command
COPY --from=jar /opt/openapi-generator/modules/openapi-generator-cli/target/openapi-generator-cli.jar /usr/bin/openapi-generator-cli.jar