36 lines
1.2 KiB
YAML
36 lines
1.2 KiB
YAML
- name: Deploy Forgejo
|
|
ansible.builtin.import_role:
|
|
name: compose-service
|
|
vars:
|
|
docker_volumes:
|
|
- '{{ data_directory }}:/data'
|
|
- /etc/timezone:/etc/timezone:ro
|
|
- /etc/localtime:/etc/localtime:ro
|
|
docker_env:
|
|
USER_UID: '{{ getent_passwd[service_user].1 }}'
|
|
USER_GID: '{{ getent_passwd[service_user].2 }}'
|
|
FORGEJO____APP_NAME: 'Korgejo'
|
|
FORGEJO____APP_SLOGAN: 'Kode hard, korge hard. Hard.'
|
|
FORGEJO__server__DOMAIN: '{{ forgejo_domain }}'
|
|
FORGEJO__server__SSH_DOMAIN: '{{ forgejo_domain }}'
|
|
FORGEJO__server__SSH_PORT: '{{ forgejo_ssh_port }}'
|
|
FORGEJO__server__ROOT_URL: 'https://{{ forgejo_domain }}/'
|
|
FORGEJO__openid__ENABLE_OPENID_SIGNIN: false
|
|
FORGEJO__openid__ENABLE_OPENID_SIGNUP: false
|
|
docker_ports:
|
|
- "{{ forgejo_ssh_port }}:22"
|
|
use_docker_user: false
|
|
|
|
- name: Ensure data directory exists
|
|
ansible.builtin.file:
|
|
path: '{{ data_directory }}'
|
|
state: directory
|
|
owner: '{{ service_user }}'
|
|
group: '{{ service_user }}'
|
|
mode: '755'
|
|
|
|
|
|
- name: Deploy Caddyfile for Forgejo
|
|
vars:
|
|
docker_http_port: 3000
|
|
ansible.builtin.import_tasks: ../../common/tasks/create_caddyfile_for_compose-service.yml
|