mirror of
https://pagure.io/fedora-infra/ansible.git
synced 2026-02-02 20:59:02 +08:00
iddev: have the playbook call certbot directly
Signed-off-by: Pierre-Yves Chibon <pingou@pingoured.fr>
This commit is contained in:
@@ -21,23 +21,16 @@
|
||||
- import_tasks: "{{ tasks_path }}/cloud_setup_basic.yml"
|
||||
- name: set hostname (required by some services, at least postfix need it)
|
||||
hostname: name="{{inventory_hostname}}"
|
||||
- name: Add an apache config to proxy letsencrypt
|
||||
shell: |
|
||||
echo '<VirtualHost *:80>
|
||||
ServerName iddev.fedorainfracloud.org
|
||||
ProxyPass "/.well-known/acme-challenge" "https://certgetter01/.well-known/acme-challenge"
|
||||
Redirect permanent / https://iddev.fedorainfracloud.org
|
||||
</VirtualHost>' > /etc/httpd/conf.d/proxy_letsencrypt.conf
|
||||
- name: reload apache
|
||||
ansible.builtin.service:
|
||||
name: httpd
|
||||
state: reloaded
|
||||
state: stopped
|
||||
- name: Letsencrypt for iddev.fedorainfracloud.org
|
||||
include_role: name=letsencrypt
|
||||
vars:
|
||||
site_name: iddev.fedorainfracloud.org
|
||||
tags:
|
||||
- letsencrypt
|
||||
shell: /usr/bin/certbot renew --noninteractive --no-random-sleep-on-renew --force-renewal --standalone
|
||||
- name: reload apache
|
||||
ansible.builtin.service:
|
||||
name: httpd
|
||||
state: restarted
|
||||
|
||||
handlers:
|
||||
- import_tasks: "{{ handlers_path }}/restart_services.yml"
|
||||
|
||||
Reference in New Issue
Block a user