From 07b3c8368031b6047db54b5a1c1a950139d0cadf Mon Sep 17 00:00:00 2001 From: Andy Zhang Date: Sat, 12 Oct 2024 17:59:32 +0800 Subject: [PATCH] chore(release): create a docker image to facilitate the update-copyright step --- scripts/Dockerfile | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100644 scripts/Dockerfile diff --git a/scripts/Dockerfile b/scripts/Dockerfile new file mode 100644 index 000000000000..154d43da0ee9 --- /dev/null +++ b/scripts/Dockerfile @@ -0,0 +1,27 @@ +FROM ubuntu:latest AS expat-build + +ARG expat_version=2.6.3 + +SHELL ["/bin/bash", "-c"] + +WORKDIR /workspace + +RUN apt update \ + && apt install -y curl + +RUN curl -L https://github.com/libexpat/libexpat/releases/download/R_${expat_version//./_}/expat-${expat_version}.tar.gz | tar -xz \ + && cd expat-${expat_version} \ + && apt install -y build-essential \ + && ./configure --prefix=/expat_lib \ + && make && make install + +FROM ubuntu:latest + +COPY --from=expat-build /expat_lib /expat_lib + +RUN apt update && apt install -y curl libssl-dev libyaml-dev lua5.4 luarocks + +WORKDIR /workspace +CMD ["/bin/bash", "-c", "OPENSSL_DIR=/usr EXPAT_DIR=/expat_lib scripts/update-copyright"] + +VOLUME /workspace