Last active
January 14, 2022 07:58
-
-
Save lwzm/a29b689d89d5bb7243db669edb156762 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
export DNSPOD_API_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx | |
export DNSPOD_HTTP_TIMEOUT=100000000 | |
CMD=run | |
CMD=renew | |
N=.lego/certificates/svc.cool | |
if ! openssl x509 -checkend 864000 -in $N.crt; then | |
lego --dns dnspod --email [email protected] \ | |
-d 'svc.cool' \ | |
-d '*.svc.cool' \ | |
$CMD | |
kubectl create secret tls lego --cert $N.crt --key $N.key --dry-run=client -o yaml | kubectl -n q apply -f - | |
fi | |
exit |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment