mirror of
https://github.com/FirebirdSQL/firebird-qa.git
synced 2025-01-22 05:23:06 +01:00
Fix usage with docker and Firebird core GH Actions workflow.
This commit is contained in:
parent
1350a7d0ae
commit
52bf714e38
16
Dockerfile
16
Dockerfile
@ -9,6 +9,7 @@ RUN \
|
||||
libtommath1 \
|
||||
python3 \
|
||||
python3-pip \
|
||||
python3-venv \
|
||||
sudo && \
|
||||
\
|
||||
rm -rf /var/lib/apt/lists/* && \
|
||||
@ -17,10 +18,10 @@ RUN \
|
||||
|
||||
ARG UID=1000
|
||||
|
||||
COPY setup.cfg pyproject.toml /qa-run/
|
||||
COPY pyproject.toml /qa-run/
|
||||
|
||||
RUN \
|
||||
useradd -u $UID user -G sudo && \
|
||||
useradd -m -u $UID user -G sudo && \
|
||||
groupadd firebird && \
|
||||
useradd --non-unique -M -b /opt -s /sbin/nologin -g firebird -u $UID firebird && \
|
||||
usermod -G sudo firebird && \
|
||||
@ -30,12 +31,17 @@ RUN \
|
||||
chown -R user:user /qa-out && \
|
||||
chown -R firebird:firebird /qa-run && \
|
||||
cd /qa-run && \
|
||||
pip install -e . && \
|
||||
pip install pytest-md-report pytest-timeout
|
||||
ln -s /qa-out out && \
|
||||
python3 -m pip install pipx
|
||||
|
||||
USER user
|
||||
|
||||
ENV PATH=/opt/firebird/bin:$PATH
|
||||
RUN \
|
||||
cd /qa-run && \
|
||||
pipx ensurepath && \
|
||||
pipx install --preinstall pytest-md-report --preinstall pytest-timeout --include-deps firebird-qa
|
||||
|
||||
ENV PATH=/opt/firebird/bin:/home/user/.local/bin:$PATH
|
||||
ENV TERMINFO_DIRS=/lib/terminfo
|
||||
ENV LD_LIBRARY_PATH=/opt/firebird/lib
|
||||
|
||||
|
@ -1,5 +1,6 @@
|
||||
#!/bin/sh
|
||||
#!/bin/bash
|
||||
set -e
|
||||
shopt -s extglob
|
||||
|
||||
mkdir /tmp/firebird-installer
|
||||
cd /tmp/firebird-installer
|
||||
@ -68,4 +69,4 @@ rm -r /tmp/firebird-installer
|
||||
mkdir /opt/firebird/examples/empbuild/qa
|
||||
chmod -R 777 /opt/firebird/examples/empbuild
|
||||
|
||||
cp -rn /qa/* /qa-run/
|
||||
cp -rn /qa/!(out) /qa-run/
|
||||
|
@ -22,4 +22,4 @@ fi
|
||||
|
||||
docker build --build-arg UID=$(id -u) --build-arg GID=$(id -g) --progress=plain -t firebird-qa $THIS_DIR
|
||||
mkdir -p $FBQA_OUT/tests
|
||||
docker run --user $(id -u) --rm -v `realpath $FBQA_OUT`:/qa-out -v `realpath $FBQA_OUT/tests`:/qa-run/out/tests -v `realpath $THIS_DIR`:/qa -v `realpath $FBQA_INSTALLER`:/firebird-installer.tar.gz firebird-qa "$@"
|
||||
docker run --user $(id -u) --rm -v `realpath $FBQA_OUT`:/qa-out -v `realpath $THIS_DIR`:/qa -v `realpath $FBQA_INSTALLER`:/firebird-installer.tar.gz firebird-qa "$@"
|
||||
|
Loading…
Reference in New Issue
Block a user