From d24f3b618b55c51ce0e4e8a9b83b67fd2ae83923 Mon Sep 17 00:00:00 2001 From: Aaron Fischer Date: Wed, 3 Aug 2022 23:06:16 +0200 Subject: [PATCH] Add some patches for the images --- Dockerfile | 7 +++++-- activate-images-permanently.patch | 25 +++++++++++++++++++++++++ 2 files changed, 30 insertions(+), 2 deletions(-) create mode 100644 activate-images-permanently.patch diff --git a/Dockerfile b/Dockerfile index 03fa134..63eefe8 100644 --- a/Dockerfile +++ b/Dockerfile @@ -9,9 +9,12 @@ WORKDIR /build COPY ./localhost.cnf /build/localhost.cnf RUN git clone https://code.rocketnine.space/tslocum/twins.git -# Apply a needed patch +RUN git config --global user.email "noname@example.com" +# Apply a needed patches COPY ./path-10.patch /build/path-10.patch -RUN cd /build/twins && patch /build/path-10.patch +RUN cd /build/twins && git am /build/path-10.patch +COPY ./activate-images-permanently.patch /build/activate-images-permanently.patch +RUN cd /build/twins && git am /build/activate-images-permanently.patch RUN cd /build/twins && go build diff --git a/activate-images-permanently.patch b/activate-images-permanently.patch new file mode 100644 index 0000000..3e7fe42 --- /dev/null +++ b/activate-images-permanently.patch @@ -0,0 +1,25 @@ +From abedd294bcae5c17cd2ecf89e1129817182f91a8 Mon Sep 17 00:00:00 2001 +From: Aaron Fischer +Date: Thu, 22 Jul 2021 22:39:47 +0200 +Subject: [PATCH] Quick and dirty image activation + +Signed-off-by: Aaron Fischer +--- + serve_https.go | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/serve_https.go b/serve_https.go +index e75e6aa..82bbf4b 100644 +--- a/serve_https.go ++++ b/serve_https.go +@@ -17,6 +17,7 @@ import ( + var cssBytes = []byte(gmitohtml.StyleCSS) + + func serveHTTPS(w http.ResponseWriter, r *http.Request) (int, int64, string) { ++ gmitohtml.Config.ConvertImages = true + if r.URL.Path == "" { + // Redirect to / + u, err := url.Parse(r.URL.String()) +-- +2.32.0 +