File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -35,6 +35,8 @@ ENV HOME=/tmp \
3535 PATH=${SONAR_SCANNER_HOME}/bin:${PATH} \
3636 SRC_PATH=/usr/src \
3737 SCANNER_WORKDIR_PATH=/tmp/.scannerwork \
38+ POETRY_CACHE_DIR=/opt/poetry/cache \
39+ POETRY_VIRTUALENVS_PATH=/opt/poetry/virtualenvs \
3840 LANG=C.UTF-8 \
3941 LC_ALL=C.UTF-8
4042
@@ -48,15 +50,21 @@ RUN \
4850 && alternatives --set node /usr/bin/node-22 \
4951 && dnf install -y python3.13 \
5052 && ln -s /usr/bin/python3.13 /usr/local/bin/python3 \
53+ && python3 -m ensurepip --upgrade \
54+ && pip3 install --no-cache-dir poetry==2.3.2 \
55+ && pip3 cache purge \
5156 && dnf clean all \
5257 && set -eux \
5358 && groupadd --system --gid 1000 scanner-cli \
5459 && useradd --system -d "${HOME}" --uid 1000 --gid scanner-cli scanner-cli \
5560 && chown -R scanner-cli:scanner-cli "${SONAR_SCANNER_HOME}" "${SRC_PATH}" \
5661 && mkdir -p "${SRC_PATH}" "${SONAR_USER_HOME}" "${SONAR_USER_HOME}/cache" "${SCANNER_WORKDIR_PATH}" \
62+ "${POETRY_CACHE_DIR}" "${POETRY_VIRTUALENVS_PATH}" \
5763 && chown -R scanner-cli:scanner-cli "${SONAR_SCANNER_HOME}" "${SRC_PATH}" "${SCANNER_WORKDIR_PATH}" \
64+ "${POETRY_CACHE_DIR}" "${POETRY_VIRTUALENVS_PATH}" \
5865 && chmod -R 555 "${SONAR_SCANNER_HOME}" \
5966 && chmod -R 754 "${SRC_PATH}" "${SONAR_USER_HOME}" "${SCANNER_WORKDIR_PATH}" \
67+ "${POETRY_CACHE_DIR}" "${POETRY_VIRTUALENVS_PATH}" \
6068 # Security updates
6169 && dnf upgrade -y --releasever=latest --security
6270
You can’t perform that action at this time.
0 commit comments