From 0d827e490ee18de4f7bf310762c39ce38f2688e1 Mon Sep 17 00:00:00 2001 From: Julien Neuhart Date: Tue, 23 Jul 2019 14:25:31 +0200 Subject: [PATCH] using (again) Golang binaries from official Docker image instead of standard install without checkum + added a TODO for healtheck --- Makefile | 2 +- build/workspace/Dockerfile | 10 +++++----- internal/app/xhttp/handler.go | 1 + 3 files changed, 7 insertions(+), 6 deletions(-) diff --git a/Makefile b/Makefile index 3a72b36e..401c7088 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -GOLANG_VERSION=1.12.7 +GOLANG_VERSION=1.12 VERSION=snapshot DOCKER_USER= DOCKER_PASSWORD= diff --git a/build/workspace/Dockerfile b/build/workspace/Dockerfile index 2ae20d7e..ecf13478 100644 --- a/build/workspace/Dockerfile +++ b/build/workspace/Dockerfile @@ -1,7 +1,9 @@ -FROM thecodingmachine/gotenberg:base - ARG GOLANG_VERSION +FROM golang:${GOLANG_VERSION}-stretch as golang + +FROM thecodingmachine/gotenberg:base + # |-------------------------------------------------------------------------- # | Common libraries # |-------------------------------------------------------------------------- @@ -25,9 +27,7 @@ RUN apt-get update && apt-get install -y --no-install-recommends \ # | Installs Golang. # | -RUN wget https://dl.google.com/go/go${GOLANG_VERSION}.linux-amd64.tar.gz &&\ - tar -xvf go${GOLANG_VERSION}.linux-amd64.tar.gz &&\ - mv go /usr/local +COPY --from=golang /usr/local/go /usr/local/go ENV GOPATH /gotenberg/go ENV PATH $GOPATH/bin:/usr/local/go/bin:$PATH diff --git a/internal/app/xhttp/handler.go b/internal/app/xhttp/handler.go index 52152fcc..ebd38499 100644 --- a/internal/app/xhttp/handler.go +++ b/internal/app/xhttp/handler.go @@ -31,6 +31,7 @@ func pingHandler(c echo.Context) error { if err := ctx.ProcessesHealthcheck(); err != nil { return xerror.New(op, err) } + // TODO return processes info return nil }