Skip to content

Instantly share code, notes, and snippets.

@mathse
Created December 3, 2015 19:40
Show Gist options
  • Save mathse/bfa812487c085939de2b to your computer and use it in GitHub Desktop.
Save mathse/bfa812487c085939de2b to your computer and use it in GitHub Desktop.
#!/bin/bash
domain=$1
alias=$2
./letsencrypt-auto certonly -a webroot --webroot-path /var/www/vhosts/$domain/httpdocs/ -d $domain -d www.$domain -d $alias -d www.$alias --server https://acme-v01.api.letsencrypt.org/directory
/usr/local/psa/bin/certificate -c "$domain letsencrypt" -domain $domain -key-file /etc/letsencrypt/live/$domain/privkey.pem -cert-file /etc/letsencrypt/live/$domain/cert.pem -cacert-file /etc/letsencrypt/live/$domain/fullchain.pem
/usr/local/psa/bin/site -u $domain -certificate-name "$domain letsencrypt"
@agarzon
Copy link

agarzon commented Dec 3, 2015

Dude, this is working for 12.5? 🔑

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment