Revert "Disable post-deploy for now"

This reverts commit bb13dd2b6f.
This commit is contained in:
Luke Murphy 2020-03-24 23:08:57 +01:00
parent cc47e9ba4d
commit c7c91a8b92
No known key found for this signature in database
GPG Key ID: 5E2EF5A63E3718CC

40
ansible/post-deploy.yml Normal file
View File

@ -0,0 +1,40 @@
---
- hosts: all
gather_facts: false
tasks:
- name: Load variables
include_vars:
dir: "{{ dokku_lib_root }}/data/ansible/drone/vars/"
extensions:
- yml
- name: Set HTTP 80 port proxy
dokku_ports:
app: drone
mappings:
- "http:80:80"
state: present
- name: Setup LE certificates
shell: dokku letsencrypt drone
args:
creates: /home/dokku/drone/letsencrypt/certs
- name: Setup LE certificates renew cron job
shell: dokku letsencrypt:cron-job --add
args:
creates: /home/dokku/drone/letsencrypt/cron-job
- name: Remove automatically configured ports
dokku_ports:
app: drone
mappings:
- "http:80:80"
state: absent
- name: Set HTTP 443 port
dokku_ports:
app: drone
mappings:
- "https:443:80"
state: present