commit a983ec659ceae2cbf4b49258114afa4f56c71c2c Author: PartTimeHarmacist Date: Thu Apr 14 22:22:33 2022 -0500 Initial Commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..ca5e3f2 --- /dev/null +++ b/.gitignore @@ -0,0 +1,2 @@ +venv/ +.idea/ \ No newline at end of file diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..b708a16 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,40 @@ +FROM pandoc/core:latest AS pandoc + +FROM gitea/gitea:latest AS gitea + +COPY --from=pandoc /usr/local/bin/pandoc /usr/local/bin/pandoc + +COPY custom/app.ini /data/gitea/conf/app.ini +COPY custom/basic.html /data/gitea/templates/basic.html + +RUN apk --no-cache add \ + asciidoctor \ + freetype \ + freetype-dev \ + gcc \ + g++ \ + libpng \ + libffi-dev \ + py-pip \ + python3-dev \ + py3-pip \ + py3-pyzmq \ + lua5.3 \ + lua5.3-lpeg \ + gmp \ + librsvg + +#RUN apk --no-cache add \ +# freetype \ +# fontconfig \ +# gnupg \ +# gzip \ +# perl \ +# tar \ +# wget \ +# xz + +RUN pip3 install --upgrade pip +RUN pip3 install -U setuptools +RUN pip3 install --ignore-installed pyzmq +RUN pip3 install jupyter docutils \ No newline at end of file diff --git a/custom/app.ini b/custom/app.ini new file mode 100644 index 0000000..5a538d4 --- /dev/null +++ b/custom/app.ini @@ -0,0 +1,16 @@ +[markup.jupyter] +ENABLED = true +FILE_EXTENSIONS = .ipynb +RENDER_COMMAND = "jupyter nbconvert --stdin --stdout --to html --template basic" +IS_INPUT_FILE = false + +[markup.sanitizer.jupyter.img] +ALLOW_DATA_URI_IMAGES = true + +[markup.docx] +ENABLED = true +FILE_EXTENSIONS = .docx +RENDER_COMMAND = "pandoc --from docx --to html --self-contained --template /data/gitea/templates/basic.html" + +[markup.sanitizer.docx.img] +ALLOW_DATA_URI_IMAGES = true \ No newline at end of file diff --git a/custom/basic.html b/custom/basic.html new file mode 100644 index 0000000..f37d7c6 --- /dev/null +++ b/custom/basic.html @@ -0,0 +1 @@ +$body$ \ No newline at end of file