Skip to content

Commit afb1261

Browse files
ecclesJAG-UK
authored andcommitted
Versioned docker images are built incorrectly
Problem: Incorrect build-arg specification. Solution: Added VERSION= at correct places. Signed-off-by: eccles <phewlett76@gmail.com>
1 parent d530250 commit afb1261

2 files changed

Lines changed: 13 additions & 5 deletions

File tree

Dockerfile-builder

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,15 @@ FROM python:${VERSION}-buster
33

44
COPY requirements.txt requirements-dev.txt /tmp/
55

6-
RUN pip3 install -r /tmp/requirements-dev.txt \
6+
RUN python3 -m pip -qq install --upgrade pip \
7+
&& python3 -m pip -qq install -U -r /tmp/requirements-dev.txt \
78
&& rm -f /tmp/requirements-dev.txt \
89
&& rm -f /tmp/requirements.txt
910

1011
ENV USER=builder
1112
ENV HOME=/home/${USER}
1213
ENV PATH=${HOME}/.local/bin:${PATH}
14+
ENV PYTHONPATH=${HOME}/archivist:${PYTHONPATH}
1315
RUN mkdir -p ${HOME}
1416
WORKDIR ${HOME}
1517

Taskfile.yml

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,22 +12,22 @@ tasks:
1212
builder:
1313
desc: Build a docker environment with the right dependencies and utilities
1414
cmds:
15-
- docker build --no-cache --build-arg 3.6 -f Dockerfile-builder -t jitsuin-archivist-python-builder .
15+
- docker build --no-cache --build-arg VERSION=3.6 -f Dockerfile-builder -t jitsuin-archivist-python-builder .
1616

1717
builder-3.7:
1818
desc: Build a docker environment with the right dependencies and utilities
1919
cmds:
20-
- docker build --no-cache --build-arg 3.7 -f Dockerfile-builder -t jitsuin-archivist-python-builder .
20+
- docker build --no-cache --build-arg VERSION=3.7 -f Dockerfile-builder -t jitsuin-archivist-python-builder .
2121

2222
builder-3.8:
2323
desc: Build a docker environment with the right dependencies and utilities
2424
cmds:
25-
- docker build --no-cache --build-arg 3.8 -f Dockerfile-builder -t jitsuin-archivist-python-builder .
25+
- docker build --no-cache --build-arg VERSION=3.8 -f Dockerfile-builder -t jitsuin-archivist-python-builder .
2626

2727
builder-3.9:
2828
desc: Build a docker environment with the right dependencies and utilities
2929
cmds:
30-
- docker build --no-cache --build-arg 3.9 -f Dockerfile-builder -t jitsuin-archivist-python-builder .
30+
- docker build --no-cache --build-arg VERSION=3.9 -f Dockerfile-builder -t jitsuin-archivist-python-builder .
3131

3232
check:
3333
desc: Check the style, bug and quality of the code
@@ -43,6 +43,12 @@ tasks:
4343
- find -name '*,cover' -type f -delete
4444
- git clean -fdX
4545

46+
docs:
47+
desc: Create sphinx documentation
48+
deps: [about]
49+
cmds:
50+
- ./scripts/builder.sh /bin/bash -c "cd docs && make html"
51+
4652
format:
4753
desc: Format code using black
4854
deps: [about]

0 commit comments

Comments
 (0)