Skip to navigation
How to use acme.sh with apache2
26.10.23
## add the below to your apache2 virtual host directive tag
```apacheconf Alias /.well-known/acme-challenge/ /var/www/letsencrypt/.well-known/acme-challenge/
Options None AllowOverride None ForceType text/plain RedirectMatch 404 "^(?!/\.well-known/acme-challenge/[\w-]{43}$)"
RewriteEngine On RewriteCond %{REQUEST_URI} !^/.well-known/acme-challenge [NC] RewriteCond %{HTTPS} off RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L] ``` ## download acme.sh, install acme.sh and create a cert ```console apt-get install git socat git clone https://github.com/acmesh-official/acme.sh.git cd acme.sh cd ./acme.sh ./acme.sh --install -m veto@myridia.com cd ~/.acme.sh ./acme.sh --test --issue -d ww1.body-piercing.com -w /var/www/letsencrypt ./acme.sh --issue -d ww1.body-piercing.com -w /var/www/letsencrypt --force
https://herrdoering.de/en/acme-sh-with-apache/
Reply
Anonymous
Information Epoch 1742052981
Avoid captive user interfaces.
Home
Notebook
Contact us