-
Notifications
You must be signed in to change notification settings - Fork 66
Expand file tree
/
Copy pathDockerfile
More file actions
37 lines (27 loc) · 1.09 KB
/
Dockerfile
File metadata and controls
37 lines (27 loc) · 1.09 KB
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
FROM python:3.12-slim AS builder
RUN apt-get update && apt-get install -y git make curl
COPY scripts/script-requirements.txt /scripts/script-requirements.txt
COPY docs docs
COPY scripts/docs/ /docs
COPY gooddata-api-client /gooddata-api-client
COPY packages/gooddata-sdk /gooddata-sdk
COPY packages/gooddata-pandas /gooddata-pandas
RUN pip install --no-cache-dir -r /scripts/script-requirements.txt
WORKDIR /docs
RUN python json_builder.py && \
python python_ref_builder.py api_spec.toml data.json latest content/en && \
mkdir versioned_docs/latest && \
mv -f data.json ./versioned_docs/latest/data.json && \
mv -f content/en/latest/links.json ./versioned_docs/latest/links.json
FROM node:20.18.0-bookworm-slim
COPY --from=builder /docs /docs
RUN apt-get update && \
apt-get install -y git make golang-go curl && \
npm install -g hugo-extended@0.117.0 && \
apt-get clean && \
rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*
WORKDIR /docs
RUN npm install && \
hugo mod get
# accessible on http://localhost:1313/latest/
ENTRYPOINT ["hugo", "server", "--bind", "0.0.0.0"]