Add Containerfile
dustin/dcow-site/pipeline/head There was a failure building this commit
Details
dustin/dcow-site/pipeline/head There was a failure building this commit
Details
parent
06ef3d4146
commit
0058f8bb4c
|
@ -0,0 +1,7 @@
|
||||||
|
*
|
||||||
|
!src/
|
||||||
|
!static/
|
||||||
|
!MANIFEST.in
|
||||||
|
!setup.py
|
||||||
|
!start.sh
|
||||||
|
!httpd.conf
|
|
@ -0,0 +1,50 @@
|
||||||
|
FROM registry.fedoraproject.org/fedora-minimal:39 AS build
|
||||||
|
|
||||||
|
RUN --mount=type=cache,target=/var/cache \
|
||||||
|
microdnf install -y \
|
||||||
|
--disablerepo=fedora-cisco-openh264 \
|
||||||
|
--setopt=install_weak_deps=0 \
|
||||||
|
python3-pip \
|
||||||
|
python3-setuptools \
|
||||||
|
python3-wheel \
|
||||||
|
&& :
|
||||||
|
|
||||||
|
COPY . /build
|
||||||
|
|
||||||
|
WORKDIR /build
|
||||||
|
|
||||||
|
RUN python3 -m pip wheel -w dist .
|
||||||
|
|
||||||
|
FROM registry.fedoraproject.org/fedora-minimal:39
|
||||||
|
|
||||||
|
RUN --mount=type=cache,target=/var/cache \
|
||||||
|
--mount=type=bind,from=build,source=/build,target=/build \
|
||||||
|
microdnf install -y \
|
||||||
|
--disablerepo=fegora-cisco-openh264 \
|
||||||
|
--setopt=install_weak_deps=0 \
|
||||||
|
httpd \
|
||||||
|
python3-setproctitle \
|
||||||
|
python3-gunicorn \
|
||||||
|
python3-pip \
|
||||||
|
tini \
|
||||||
|
&& python3 -m pip install --no-index -f /build/dist DarkChestOfWonders \
|
||||||
|
&& install -o apache -g apache -d /data/screenshots /data/thumbnails \
|
||||||
|
&& chown apache: /var/log/httpd /var/run/httpd \
|
||||||
|
&& install /build/start.sh / \
|
||||||
|
&& sed -i \
|
||||||
|
-e 's/Listen 80/Listen 8204/' \
|
||||||
|
-e 's:logs/error_log:/dev/stderr:g' \
|
||||||
|
-e 's:logs/access_log:/dev/stderr:g' \
|
||||||
|
/etc/httpd/conf/httpd.conf \
|
||||||
|
&& cp /build/httpd.conf /etc/httpd/conf.d/ \
|
||||||
|
&& :
|
||||||
|
|
||||||
|
EXPOSE 8204
|
||||||
|
|
||||||
|
USER apache
|
||||||
|
|
||||||
|
VOLUME /data
|
||||||
|
|
||||||
|
WORKDIR /data
|
||||||
|
|
||||||
|
ENTRYPOINT ["tini", "/start.sh"]
|
|
@ -0,0 +1,11 @@
|
||||||
|
ServerName 127.0.0.1
|
||||||
|
|
||||||
|
Alias /screenshots /data/screenshots
|
||||||
|
|
||||||
|
<Directory /data/screenshots>
|
||||||
|
Require all granted
|
||||||
|
</Directory>
|
||||||
|
|
||||||
|
ProxyPass /screenshots !
|
||||||
|
ProxyPass / http://127.0.0.1:8000/
|
||||||
|
ProxyPassReverse / http://127.0.:0.1:8000/
|
Loading…
Reference in New Issue