45 lines
1.1 KiB
YAML
45 lines
1.1 KiB
YAML
|
---
|
||
|
- hosts: all
|
||
|
gather_facts: false
|
||
|
tasks:
|
||
|
- name: Load variables
|
||
|
include_vars:
|
||
|
dir: "{{ dokku_lib_root }}/data/ansible/drone/vars/"
|
||
|
extensions:
|
||
|
- yml
|
||
|
|
||
|
- name: "Configure {{ domain }} domain"
|
||
|
dokku_domains:
|
||
|
app: drone
|
||
|
domains:
|
||
|
- "{{ domain }}"
|
||
|
state: present
|
||
|
|
||
|
- name: Create application directory
|
||
|
file:
|
||
|
path: /var/lib/drone
|
||
|
state: directory
|
||
|
owner: dokku
|
||
|
group: dokku
|
||
|
become: true
|
||
|
|
||
|
- name: Specify docker volume mounts
|
||
|
dokku_storage:
|
||
|
app: drone
|
||
|
mounts:
|
||
|
- /var/lib/drone:/data
|
||
|
|
||
|
- name: Configure the app environment
|
||
|
dokku_config:
|
||
|
app: drone
|
||
|
restart: false
|
||
|
config:
|
||
|
DOKKU_LETSENCRYPT_EMAIL: "{{ autonomic_admin_mail }}"
|
||
|
DRONE_GITEA_CLIENT_ID: "{{ gitea_client_id }}"
|
||
|
DRONE_GITEA_CLIENT_SECRET: "{{ gitea_client_secret }}"
|
||
|
DRONE_GITEA_SERVER: "{{ gitea_domain }}"
|
||
|
DRONE_GIT_ALWAYS_AUTH: "true"
|
||
|
DRONE_RPC_SECRET: "{{ rpc_secret }}"
|
||
|
DRONE_SERVER_HOST: "{{ domain }}"
|
||
|
DRONE_SERVER_PROTO: "https"
|