Open annerajb opened 7 years ago
I pulled down your code and did a local build, but still get the same auth-header error...
8/11/2017 11:34:23 AMtime="2017-08-11T18:34:23Z" level=error msg="[mydomain.com] Error obtaining certificate: Error presenting token: dns.ZonesClient#Get: Failure responding to request: StatusCode=401 -- Original Error: autorest/azure: Service returned an error. Status=401 Code=\"AuthenticationFailed\" Message=\"Authentication failed. The 'Authorization' header is missing.\""
After looking at the Dockerfile, I think it's just pulling down a binary of the last build... I'll keep looking. Would love to validate this for you (which would mean it works for all of us!)
I was not able to get it working either. Had issues with the setup of the build environment. The xenolf/Lego guys told me to update the libraries.
Unfortunately, i don't know go
... so we'll see!
I made a new Dockerfile
to make sure I was picking up the new build, and looks like it's still generating the error, so unfortunately updating the libraries hasn't resolved this issue...
Dockerfile for reference (run from repo root):
FROM golang:alpine AS build-env
RUN apk add --update make git
WORKDIR /src
ADD . .
RUN go get github.com/Sirupsen/logrus
RUN go get github.com/janeczku/rancher-letsencrypt/letsencrypt
RUN make build
# final stage
FROM alpine:3.5
COPY --from=build-env /src/build/rancher-letsencrypt-linux-amd64 /usr/bin/rancher-letsencrypt
COPY package/rancher-entrypoint.sh /usr/bin/
RUN apk add --no-cache ca-certificates openssl bash &&\
wget -O /usr/bin/update-rancher-ssl https://raw.githubusercontent.com/rancher/rancher/08278ace626ada71384fc949bd637f4c15b03b53/server/bin/update-rancher-ssl && \
chmod +x /usr/bin/update-rancher-ssl &&\
chmod +x /usr/bin/rancher-letsencrypt
EXPOSE 80
ENTRYPOINT ["/usr/bin/rancher-entrypoint.sh"]
That dockerfile is downloading janeczku/rancher-letsencrypt repo the fixes for the authentication header are in annerajb/rancher-letsencrypt.
If you modify the dockerfile it causes another issue The context.go requires updating from looking for janeczku/rancher-letsencrypt to annerajb/rancher-letsencrypt.
I have no idea why people do this in GO.... but I haven't worked more than 2 hours with it.(for fixing this issue)
and obviously circleci failed since it's hardcoded to only pull this repository.... to the go vendor folder.
Maybe anybody with access to the original repo can help on how to update that go dependency? To this same repo?
@annerajb nobody did deploy your fix?
nope i ended up using the cname option.
On Tue, Feb 12, 2019 at 4:48 PM Patrick Machado notifications@github.com wrote:
@annerajb https://github.com/annerajb nobody did deploy your fix?
— You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub https://github.com/janeczku/rancher-letsencrypt/pull/90#issuecomment-462949535, or mute the thread https://github.com/notifications/unsubscribe-auth/AA14XgEIeHJDaEfVhL6GV53y-e42A-VYks5vMzaigaJpZM4O0uYv .
Fixes #89
Can you verify this?