首页 > 解决方案 > social-bunch.site (http-01): urn:ietf:params:acme:error:unauthorized :: 客户端缺乏足够的授权 ::

问题描述

我正在利用这篇文章尝试为 Docker、nginx、节点获取 Lets Ecrypt 证书,但出现此错误

Failed authorization procedure. social-bunch.site (http-01): urn:ietf:params:acme:error:unauthorized :: The client lacks sufficient authorization :: Invalid response from ://social-bunch.site/.well-known/acme-challenge

我花了很长时间来构建这个项目,现在已经好几天才能获得一个血腥的 SSL 证书。所以我很感激帮助。这是我的 Dockerfile

FROM node as build
WORKDIR /usr/app
COPY ./client .
RUN yarn install && yarn build

FROM nginx
RUN rm /etc/nginx/conf.d/default.conf
COPY ./nginx/nginx.conf /etc/nginx/nginx.conf
COPY --from=build /usr/app/build /usr/share/nginx/html
ARG CERTBOT_EMAIL=info@domain.com
ARG DOMAIN_LIST

RUN  apt-get update \
    && apt-get install -y cron certbot python-certbot-nginx bash wget \
    && certbot certonly --standalone --agree-tos -m "${CERTBOT_EMAIL}" -n -d ${DOMAIN_LIST} \
    && rm -rf /var/lib/apt/lists/* \
    && echo "@monthly certbot renew --nginx >> /var/log/cron.log 2>&1" >/etc/cron.d/certbot-renew \
    && crontab /etc/cron.d/certbot-renew
VOLUME /etc/letsencrypt
CMD [ "sh", "-c", "cron && nginx -g 'daemon off;'" ]

标签: node.jsnginxssllets-encrypt

解决方案


推荐阅读