Ansible roles by Evolix
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Jérémy Lecour 2c11f02554 Merge branch 'unstable' of evolix/ansible-roles into stable 11 months ago
..
defaults evoacme: install hooks 2 years ago
files Remove chown root: /etc/ssl/private in make-csr.sh 1 year ago
handlers Better squid/squid3 whitelist and reload 2 years ago
meta change repositories URL 1 year ago
tasks evoacme: add a renewal hook to commit changes in /etc/.git 1 year ago
templates evoacme: fix module detection in apache config 1 year ago
tests Add some kitchen tests for many roles 2 years ago
.kitchen.yml Kitchen: Change base image to evolix/ansible 2 years ago
README.md Merge branch 'unstable' of evolix/ansible-roles into stable 11 months ago

README.md

Evoacme 2.0

EvoAcme is an Ansible role and a Certbot wrapper for generate Let's Encrypt certificates.

It is a project hosted at Evolix's forge

Evoacme is open source software licensed under the AGPLv3 License.

Install

1 - Create a playbook with evoacme role

---
- hosts: hostname
  become: yes
  roles:
    - evoacme

2 - Install evoacme prerequisite with ansible

# ansible-playbook playbook.yml -K --diff --check --limit hostname

3 - Include letsencrypt.conf in your webserver

For Apache, you just need to ensure that you don't overwrite “/.well-known/acme-challenge” Alias with a Redirect or Rewrite directive.

For Nginx, you must include /etc/nginx/snippets/letsencrypt.conf in all wanted vhosts :

server {
    […]
    include /etc/nginx/snippets/letsencrypt.conf;
    […]
}

then reload the Nginx configuration :

# nginx -t
# service nginx reload

4 - Create a CSR for a vhost with make-csr

# make-csr vhostname domain...

5 - Generate the certificate with evoacme

# evoacme look for /etc/ssl/requests/vhostname
# vhostname was the same used by make-csr
evoacme vhostname

6 - Include ssl configuration

Sll configuration has generated, you must include it in your vhost.

For Apache :

Include /etc/apache2/ssl/vhost.conf

For Nginx :

include /etc/nginx/ssl/vhost.conf;