diff options
author | Egor Tensin <Egor.Tensin@gmail.com> | 2022-03-26 12:44:29 +0300 |
---|---|---|
committer | Egor Tensin <Egor.Tensin@gmail.com> | 2022-03-26 12:44:31 +0300 |
commit | 0f5dbcc3bdeb401f00c1cdcb7b0ef826003b5bd7 (patch) | |
tree | d6d591ba8845d6cda37c756a44f9c92605c7df09 /docker/frontend/Dockerfile | |
parent | docker: run once at startup, even when in cron (diff) | |
download | cgitize-0f5dbcc3bdeb401f00c1cdcb7b0ef826003b5bd7.tar.gz cgitize-0f5dbcc3bdeb401f00c1cdcb7b0ef826003b5bd7.zip |
docker: add a frontend nginx image
At first, I built a custom image at https://egort.name/. It had a rather
long development history, and I just copied the files from there.
Diffstat (limited to '')
-rw-r--r-- | docker/frontend/Dockerfile | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/docker/frontend/Dockerfile b/docker/frontend/Dockerfile new file mode 100644 index 0000000..5fb1960 --- /dev/null +++ b/docker/frontend/Dockerfile @@ -0,0 +1,19 @@ +FROM nginx:1 + +RUN export DEBIAN_FRONTEND=noninteractive && \ + runtime_deps='cgit cmark-gfm fcgiwrap tini' && \ + apt-get update && \ + apt-get install -y --no-install-recommends $runtime_deps && \ + # Install the latest Pygments (so that it would highlight CMakeLists.txt, etc.): + apt-get install -y --no-install-recommends python3-pip && \ + pip3 install --no-cache-dir pygments~=2.0 && \ + # Replace the theme with the one I like better: + grep -q -F -- "style='pastie'" /usr/lib/cgit/filters/syntax-highlighting.py && \ + sed -i -e "s/style='pastie'/style='vs'/" -- /usr/lib/cgit/filters/syntax-highlighting.py + +COPY ["etc/", "/etc/"] +COPY ["usr/", "/usr/"] +COPY ["cmd.sh", "/"] + +ENTRYPOINT ["/usr/bin/tini", "--"] +CMD ["/cmd.sh"] |