feat: automatic ssl certificate
This commit is contained in:
parent
6179dea246
commit
1007055da4
3 changed files with 62 additions and 4 deletions
|
@ -4,6 +4,16 @@ RUN /usr/local/openresty/luajit/bin/luarocks install lua-resty-http
|
|||
RUN /usr/local/openresty/luajit/bin/luarocks install lua-resty-cookie
|
||||
RUN /usr/local/openresty/luajit/bin/luarocks install lua-resty-iputils
|
||||
|
||||
RUN apk add openssl
|
||||
RUN /usr/local/openresty/luajit/bin/luarocks install lua-resty-auto-ssl
|
||||
|
||||
RUN mkdir /etc/resty-auto-ssl && chown -R nobody /etc/resty-auto-ssl
|
||||
|
||||
RUN openssl req -new -newkey rsa:2048 -days 3650 -nodes -x509 \
|
||||
-subj '/CN=fallback.invalid' \
|
||||
-keyout /etc/ssl/resty-auto-ssl-fallback.key \
|
||||
-out /etc/ssl/resty-auto-ssl-fallback.crt
|
||||
|
||||
COPY default.conf /etc/nginx/conf.d/default.conf
|
||||
COPY env.main /etc/nginx/conf.d/env.main
|
||||
COPY lua/* /opt/sitelen-tu/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue