File Dockerfile of Package opensuse-quiz

# SPDX-License-Identifier: MIT
#!BuildTag: opensuse/quiz:latest opensuse/quiz:1.0 opensuse/quiz:1.0.%RELEASE%
# labelprefix=org.opensuse.quiz

FROM opensuse/tumbleweed

LABEL org.opencontainers.image.title="openSUSE quiz container"
LABEL org.opencontainers.image.description="Container with opensuse-quiz-app 1.0.0"
LABEL org.opencontainers.image.version="1.0.%.%RELEASE%"
LABEL org.opensuse.reference="registry.opensuse.org/opensuse/quiz:1.0.0.%RELEASE%"
LABEL org.openbuildservice.disturl="%DISTURL%"
LABEL org.opencontainers.image.created="%BUILDTIME%"

# Install Git to clone the source
RUN zypper --non-interactive in nodejs npm git python3

VOLUME /usr/src/app/data

# Set working directory
WORKDIR /usr/src/app

# Clone the GitHub repository
#RUN git clone --depth 1 https://github.com/openSUSE/quiz.git .

COPY entrypoint.sh /usr/local/bin/entrypoint.sh
RUN set -euo pipefail; chmod +x /usr/local/bin/entrypoint.sh

RUN useradd -mU quiz

RUN chown -R quiz /usr/src/app
RUN chown -R quiz /usr/src/app/data

USER quiz

ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]
openSUSE Build Service is sponsored by