| 1 | ACME_EMAIL="alais@example.org" |
| 2 | PORKBUN_API_KEY="pk1_000000000000000000000000000000000000000000000000000000" |
| 3 | PORKBUN_API_SECRET="sk1_000000000000000000000000000000000000000000000000000000" |
| 4 | DOMAIN="example.org" |
| 5 |
_README.md
· 420 B · Markdown
Raw
On your server, create a folder and add the two files below that are attached to this Gist:
```
mkdir ~/certbot-porkbun-dns
cd ~/certbot-porkbun-dns
```
Pull image:
```
docker compose pull
```
Set a domain in `.env` that you'll want to generate a certificate for, then run:
```
docker compose up
```
Wait a minute and it should generate.
> Use the provided `fullchain.pem` and `privkey.pem` files that are generated.
On your server, create a folder and add the two files below that are attached to this Gist:
mkdir ~/certbot-porkbun-dns
cd ~/certbot-porkbun-dns
Pull image:
docker compose pull
Set a domain in .env that you'll want to generate a certificate for, then run:
docker compose up
Wait a minute and it should generate.
Use the provided
fullchain.pemandprivkey.pemfiles that are generated.
docker-compose.yml
· 526 B · YAML
Raw
services:
certbot_dns_porkbun:
image: infinityofspace/certbot_dns_porkbun:latest
command: certonly --non-interactive --agree-tos --email ${ACME_EMAIL}
--preferred-challenges dns --authenticator dns-porkbun
--dns-porkbun-key ${PORKBUN_API_KEY} --dns-porkbun-secret
${PORKBUN_API_SECRET} --dns-porkbun-propagation-seconds 60 -d
"${DOMAIN}"
volumes:
- /etc/letsencrypt:/etc/letsencrypt
- /var/log/letsencrypt:/var/log/letsencrypt
| 1 | services: |
| 2 | certbot_dns_porkbun: |
| 3 | image: infinityofspace/certbot_dns_porkbun:latest |
| 4 | command: certonly --non-interactive --agree-tos --email ${ACME_EMAIL} |
| 5 | --preferred-challenges dns --authenticator dns-porkbun |
| 6 | --dns-porkbun-key ${PORKBUN_API_KEY} --dns-porkbun-secret |
| 7 | ${PORKBUN_API_SECRET} --dns-porkbun-propagation-seconds 60 -d |
| 8 | "${DOMAIN}" |
| 9 | volumes: |
| 10 | - /etc/letsencrypt:/etc/letsencrypt |
| 11 | - /var/log/letsencrypt:/var/log/letsencrypt |