diff --git a/Dockerfile--altlinux_10.tmpl b/Dockerfile--altlinux_10.tmpl index 5752b698..e82c9398 100644 --- a/Dockerfile--altlinux_10.tmpl +++ b/Dockerfile--altlinux_10.tmpl @@ -64,19 +64,8 @@ RUN ln -s /pg/postgres/install/lib/libpq.so.5.17 /usr/lib64/libpq.so.5 FROM base1_with_pg-${PG_VERSION} as base2_with_python-3 RUN apt-get install -y python3 RUN apt-get install -y python3-dev -RUN apt-get install -y python3-module-virtualenv RUN apt-get install -y python3-modules-sqlite3 -# AltLinux does not have "generic" virtualenv utility. Let's create it. -RUN if [[ -f "/usr/bin/virtualenv" ]] ; then \ - echo AAA; \ - elif [[ -f "/usr/bin/virtualenv3" ]] ; then \ - ln -s /usr/bin/virtualenv3 /usr/bin/virtualenv; \ - else \ - echo "/usr/bin/virtualenv is not created!"; \ - exit 1; \ - fi - ENV PYTHON_VERSION=3 # --------------------------------------------- final @@ -101,8 +90,6 @@ RUN mkdir -p ~/.ssh # # Altlinux 10 and 11 too slowly create a new SSH connection (x6). # -# So, we exclude the "remote" tests until this problem has been resolved. -# ENTRYPOINT sh -c " \ set -eux; \ diff --git a/Dockerfile--altlinux_11.tmpl b/Dockerfile--altlinux_11.tmpl index 5d3615fe..cf549926 100644 --- a/Dockerfile--altlinux_11.tmpl +++ b/Dockerfile--altlinux_11.tmpl @@ -67,19 +67,8 @@ RUN ln -s /pg/postgres/install/lib/libpq.so.5.17 /usr/lib64/libpq.so.5 FROM base1_with_pg-${PG_VERSION} as base2_with_python-3 RUN apt-get install -y python3 RUN apt-get install -y python3-dev -RUN apt-get install -y python3-module-virtualenv RUN apt-get install -y python3-modules-sqlite3 -# AltLinux does not have "generic" virtualenv utility. Let's create it. -RUN if [[ -f "/usr/bin/virtualenv" ]] ; then \ - echo AAA; \ - elif [[ -f "/usr/bin/virtualenv3" ]] ; then \ - ln -s /usr/bin/virtualenv3 /usr/bin/virtualenv; \ - else \ - echo "/usr/bin/virtualenv is not created!"; \ - exit 1; \ - fi - ENV PYTHON_VERSION=3 # --------------------------------------------- final @@ -104,8 +93,6 @@ RUN mkdir -p ~/.ssh # # Altlinux 10 and 11 too slowly create a new SSH connection (x6). # -# So, we exclude the "remote" tests until this problem has been resolved. -# ENTRYPOINT sh -c " \ set -eux; \ diff --git a/Dockerfile--std-all.tmpl b/Dockerfile--std-all.tmpl index e05acd87..7ebb6194 100644 --- a/Dockerfile--std-all.tmpl +++ b/Dockerfile--std-all.tmpl @@ -6,7 +6,7 @@ FROM postgres:${PG_VERSION}-alpine as base1 # --------------------------------------------- base2_with_python-3 FROM base1 as base2_with_python-3 -RUN apk add --no-cache curl python3 python3-dev build-base musl-dev linux-headers py-virtualenv +RUN apk add --no-cache curl python3 python3-dev build-base musl-dev linux-headers ENV PYTHON_VERSION=3 # --------------------------------------------- final diff --git a/Dockerfile--std.tmpl b/Dockerfile--std.tmpl index f0bbf5b5..76e004f0 100644 --- a/Dockerfile--std.tmpl +++ b/Dockerfile--std.tmpl @@ -6,7 +6,7 @@ FROM postgres:${PG_VERSION}-alpine as base1 # --------------------------------------------- base2_with_python-3 FROM base1 as base2_with_python-3 -RUN apk add --no-cache curl python3 python3-dev build-base musl-dev linux-headers py-virtualenv +RUN apk add --no-cache curl python3 python3-dev build-base musl-dev linux-headers ENV PYTHON_VERSION=3 # --------------------------------------------- final diff --git a/Dockerfile--ubuntu_24_04.tmpl b/Dockerfile--ubuntu_24_04.tmpl index bb77b84a..ca26afea 100644 --- a/Dockerfile--ubuntu_24_04.tmpl +++ b/Dockerfile--ubuntu_24_04.tmpl @@ -41,7 +41,7 @@ RUN sh -c "echo postgres ALL=NOPASSWD:/usr/sbin/service ssh start" >> /etc/sudoe # --------------------------------------------- base2_with_python-3 FROM base1 as base2_with_python-3 -RUN apt install -y python3 python3-dev python3-virtualenv libpq-dev +RUN apt install -y python3 python3-dev python3-venv libpq-dev build-essential ENV PYTHON_VERSION=3 # --------------------------------------------- final diff --git a/run_tests.sh b/run_tests.sh index 5dc0e444..f4a978c6 100755 --- a/run_tests.sh +++ b/run_tests.sh @@ -13,7 +13,7 @@ command -v pg_config # prepare python environment VENV_PATH="/tmp/testgres_venv" rm -rf $VENV_PATH -virtualenv --python="/usr/bin/python${PYTHON_VERSION}" "${VENV_PATH}" +python${PYTHON_VERSION} -m venv "${VENV_PATH}" export VIRTUAL_ENV_DISABLE_PROMPT=1 source "${VENV_PATH}/bin/activate" pip install -r tests/requirements.txt