Skip to content
Snippets Groups Projects
Commit ad5ab364 authored by void's avatar void
Browse files

Upgrade uffd to 2.3.1 and switch back to main Version

parent 1045cda5
No related branches found
No related tags found
No related merge requests found
FROM debian:bookworm AS build-stage
FROM debian:bullseye
ENV DEBIAN_FRONTEND=noninteractive
ENV PYBUILD_INSTALL_ARGS="--install-lib=/usr/share/uffd/ --install-scripts=/usr/share/uffd/"
ENV PACKAGE_VERSION=v2.3.1.r21
# Install depandencies
RUN set -x && \
apt update && \
apt install -y --no-install-recommends \
lsb-release \
curl \
ca-certificates \
locales-all \
git \
python3 \
python3-venv \
python3-coverage \
python3-ldap3 \
python3-flask \
python3-flask-sqlalchemy \
python3-flask-migrate \
python3-pip \
python3-qrcode \
python3-fido2 \
python3-oauthlib \
python3-flask-babel \
python3-argon2 \
python3-pytest \
python3-all \
python3-pip \
git-buildpackage \
debhelper \
build-essential \
dh-python \
python3-mysqldb \
python3-requests-oauthlib \
python3-git \
python3-prometheus-client \
libffi-dev \
python3-build \
twine && \
apt -qq clean
RUN git clone https://git.cccv.de/uffd/uffd.git
WORKDIR /uffd
RUN git checkout 3f41d2fb7f686c12a1f09577e5b96da89ff46e07
RUN set -x && \
./debian/create_changelog.py uffd > debian/changelog && \
dpkg-buildpackage -us -uc && \
dpkg-deb -I /*.deb && \
dpkg-deb -c /*.deb && \
mv /*.deb /uffd/uffd.deb
FROM debian:bookworm as app-stage
COPY --from=build-stage /uffd/uffd.deb /uffd.deb
ca-certificates \
curl \
gnupg2 \
python3 \
python3-argon2 \
python3-cryptography \
python3-fido2 \
python3-flask \
python3-flask-babel \
python3-flask-sqlalchemy \
python3-flask-migrate \
python3-itsdangerous \
python3-jwt \
python3-qrcode \
python3-prometheus-client \
python3-pymysql \
python3-oauthlib \
python3-uaparser \
wget && \
rm -rf /var/lib/apt/lists/*
# Install uffd from CCCV Repo
RUN set -x && \
echo "deb https://packages.cccv.de/uffd bullseye main" > /etc/apt/sources.list.d/cccv-archive-bullseye.list && \
curl -sS https://packages.cccv.de/docs/cccv-archive-key.gpg | gpg --dearmor --yes -o /etc/apt/trusted.gpg.d/cccv-archive-key.gpg && \
apt update && \
apt install -y --no-install-recommends /uffd.deb python3-psycopg2 python3-pymysql && \
rm -rf /var/lib/apt/lists/* && \
rm /uffd.deb && \
cat /etc/uffd/uffd.cfg | grep -v "SECRET_KEY=" > /etc/uffd/uffd.cfg.tmp && \
mv /etc/uffd/uffd.cfg.tmp /etc/uffd/uffd.cfg && \
mkdir --parents /var/www/uffd && \
chown root:uffd /var/www/uffd
apt install -y --no-install-recommends uffd=2.3.1 && \
rm -rf /var/lib/apt/lists/*
COPY entrypoint.sh /entrypoint.sh
......
FROM debian:bookworm AS build-stage
ENV DEBIAN_FRONTEND=noninteractive
ENV PYBUILD_INSTALL_ARGS="--install-lib=/usr/share/uffd/ --install-scripts=/usr/share/uffd/"
ENV PACKAGE_VERSION=v2.3.1.r21
RUN set -x && \
apt update && \
apt install -y --no-install-recommends \
lsb-release \
curl \
ca-certificates \
locales-all \
git \
python3 \
python3-venv \
python3-coverage \
python3-ldap3 \
python3-flask \
python3-flask-sqlalchemy \
python3-flask-migrate \
python3-pip \
python3-qrcode \
python3-fido2 \
python3-oauthlib \
python3-flask-babel \
python3-argon2 \
python3-pytest \
python3-all \
python3-pip \
git-buildpackage \
debhelper \
build-essential \
dh-python \
python3-mysqldb \
python3-requests-oauthlib \
python3-git \
python3-prometheus-client \
libffi-dev \
python3-build \
twine && \
apt -qq clean
RUN git clone https://git.cccv.de/uffd/uffd.git
WORKDIR /uffd
RUN git checkout 3f41d2fb7f686c12a1f09577e5b96da89ff46e07
RUN set -x && \
./debian/create_changelog.py uffd > debian/changelog && \
dpkg-buildpackage -us -uc && \
dpkg-deb -I /*.deb && \
dpkg-deb -c /*.deb && \
mv /*.deb /uffd/uffd.deb
FROM debian:bookworm as app-stage
COPY --from=build-stage /uffd/uffd.deb /uffd.deb
RUN set -x && \
apt update && \
apt install -y --no-install-recommends /uffd.deb python3-psycopg2 python3-pymysql && \
rm -rf /var/lib/apt/lists/* && \
rm /uffd.deb && \
cat /etc/uffd/uffd.cfg | grep -v "SECRET_KEY=" > /etc/uffd/uffd.cfg.tmp && \
mv /etc/uffd/uffd.cfg.tmp /etc/uffd/uffd.cfg && \
mkdir --parents /var/www/uffd && \
chown root:uffd /var/www/uffd
COPY entrypoint.sh /entrypoint.sh
USER uffd
USER root
EXPOSE 3031/tcp
EXPOSE 9191/tcp
CMD bash /entrypoint.sh
......@@ -7,7 +7,7 @@
db_ready="false"
count=0
while [ $count -lt 32 ] && [ "$db_ready" != "true" ] ;do
if uffd-admin db current >> /dev/null 2>&1 ;then
if [ -z "$(uffd-admin db current 2>&1 | grep -o "Error")" ] ;then
db_ready="true"
else
echo "Waiting for db to become ready..."
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment