-
Notifications
You must be signed in to change notification settings - Fork 4
/
Dockerfile.cicd
39 lines (31 loc) · 1.31 KB
/
Dockerfile.cicd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
FROM rust:slim-buster as rust
RUN cargo install just
FROM openapitools/openapi-generator-cli:v7.0.1 as maven
RUN apt update && apt -y install jq git gettext-base libicu-dev
# need to install the following for python
RUN apt install -y build-essential zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev libssl-dev libsqlite3-dev libreadline-dev libffi-dev curl libbz2-dev liblzma-dev \
&& cd tmp \
&& curl -O https://www.python.org/ftp/python/3.8.2/Python-3.8.2.tar.xz \
&& tar -xf Python-3.8.2.tar.xz \
&& cd Python-3.8.2 \
&& ./configure --enable-optimizations --enable-loadable-sqlite-extensions \
&& make -j 4 \
&& make altinstall \
&& ln -s $(which python3.8) /usr/bin/python3 \
&& curl -sSL https://install.python-poetry.org | python3 -
ENV PATH=${PATH}:/root/.local/bin
COPY --from=rust /usr/local/cargo/bin/just /usr/bin/just
# need to test that just is going to work.
RUN just --help
RUN mkdir -p /tmp/docs
RUN mkdir -p /tmp/workflows
RUN mkdir -p /usr/src/generate
WORKDIR /usr/src/
COPY docs/. /tmp/docs/
COPY workflows/. /tmp/workflows/
COPY generate/ /usr/src/generate
COPY ./justfile /usr/src/justfile
COPY test_sdk /usr/src/test_sdk
# sometimes poetry publish fails due to connection timeouts
# default is 15 secs, I've increased to 120 to mitigate.
ENV POETRY_REQUESTS_TIMEOUT=120