Skip to content

Commit bad8c6a

Browse files
committed
fix: reduce docker layer and remove user flag from pip install
1 parent 80e2c8e commit bad8c6a

File tree

4 files changed

+6
-8
lines changed

4 files changed

+6
-8
lines changed

deployment/docker/runner/Dockerfile

+2-3
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,8 @@ USER 1001
5353
# renovate: datasource=pypi depName=ansible
5454
ENV ANSIBLE_VERSION 9.4.0
5555

56-
RUN mkdir /opt/semaphore/venv
57-
58-
RUN python3 -m venv /opt/semaphore/venv --system-site-packages && \
56+
RUN mkdir /opt/semaphore/venv && \
57+
python3 -m venv /opt/semaphore/venv --system-site-packages && \
5958
source /opt/semaphore/venv/bin/activate && \
6059
pip3 install --upgrade pip ansible==${ANSIBLE_VERSION} boto3 botocore requests
6160

deployment/docker/runner/runner-wrapper

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ fi
1818

1919
if test -f "${SEMAPHORE_CONFIG_PATH}/requirements.txt"; then
2020
echoerr "Installing additional python dependencies"
21-
pip3 install --upgrade --user \
21+
pip3 install --upgrade \
2222
-r "${SEMAPHORE_CONFIG_PATH}/requirements.txt"
2323
else
2424
echoerr "No additional python dependencies to install"

deployment/docker/server/Dockerfile

+2-3
Original file line numberDiff line numberDiff line change
@@ -53,9 +53,8 @@ USER 1001
5353
# renovate: datasource=pypi depName=ansible
5454
ENV ANSIBLE_VERSION 9.4.0
5555

56-
RUN mkdir /opt/semaphore/venv
57-
58-
RUN python3 -m venv /opt/semaphore/venv --system-site-packages && \
56+
RUN mkdir /opt/semaphore/venv && \
57+
python3 -m venv /opt/semaphore/venv --system-site-packages && \
5958
source /opt/semaphore/venv/bin/activate && \
6059
pip3 install --upgrade pip ansible==${ANSIBLE_VERSION} boto3 botocore requests
6160

deployment/docker/server/server-wrapper

+1-1
Original file line numberDiff line numberDiff line change
@@ -190,7 +190,7 @@ fi
190190

191191
if test -f "${SEMAPHORE_CONFIG_PATH}/requirements.txt"; then
192192
echoerr "Installing additional python dependencies"
193-
pip3 install --upgrade --user \
193+
pip3 install --upgrade \
194194
-r "${SEMAPHORE_CONFIG_PATH}/requirements.txt"
195195
else
196196
echoerr "No additional python dependencies to install"

0 commit comments

Comments
 (0)