testing
This commit is contained in:
parent
aa9aa8985b
commit
30900bb721
@ -5,7 +5,8 @@
|
||||
- host_vars/proxy.yml
|
||||
roles:
|
||||
- base
|
||||
- postgresql
|
||||
- proxy
|
||||
- docker
|
||||
- bitwarden
|
||||
- gitea
|
||||
- bitwarden
|
||||
|
@ -3,6 +3,8 @@ gitea_name: gitea
|
||||
gitea_sshport: "222"
|
||||
gitea_webport: "3000"
|
||||
gitea_volume: "{{ gitea_name }}"
|
||||
gitea_rooturl: "http://{{ gitea_domain }}"
|
||||
gitea_signup: true
|
||||
|
||||
# database settings
|
||||
gitea_dbtype: postgres
|
||||
|
@ -3,6 +3,16 @@
|
||||
path: "{{ gitea_root }}"
|
||||
state: directory
|
||||
|
||||
- name: Create gitea database
|
||||
postgresql_db:
|
||||
name: "{{ gitea_dbname }}"
|
||||
|
||||
- name: Create gitea database user
|
||||
postgresql_user:
|
||||
db: "{{ gitea_dbname }}"
|
||||
name: "{{ gitea_dbuser }}"
|
||||
password: "{{ gitea_dbpass }}"
|
||||
|
||||
- name: Install Gitea's docker-compose file
|
||||
template:
|
||||
src: docker-compose.yml.j2
|
||||
|
@ -1,6 +1,8 @@
|
||||
# {{ ansible_managed }}
|
||||
gitea_version={{ gitea_version }}
|
||||
gitea_name={{ gitea_name }}
|
||||
gitea_domain={{ gitea_domain }}
|
||||
gitea_rooturl={{ gitea_rooturl }}
|
||||
gitea_webport={{ gitea_webport }}
|
||||
gitea_sshport={{ gitea_sshport }}
|
||||
gitea_dbtype={{ gitea_dbtype }}
|
||||
@ -8,3 +10,8 @@ gitea_dbhost={{ gitea_dbhost }}
|
||||
gitea_dbname={{ gitea_dbname }}
|
||||
gitea_dbuser={{ gitea_dbuser }}
|
||||
gitea_dbpass={{ gitea_dbpass }}
|
||||
{% if not gitea_signup %}
|
||||
gitea_disable_registration=true
|
||||
{% else %}
|
||||
gitea_disable_registration=false
|
||||
{% endif %}
|
||||
|
@ -5,17 +5,22 @@ services:
|
||||
image: "gitea/gitea:${gitea_version}"
|
||||
container_name: "${gitea_name}"
|
||||
ports:
|
||||
- "${gitea_webport}:3000"
|
||||
- "${gitea_sshport}:22"
|
||||
- "127.0.0.1:5432:5432"
|
||||
- "127.0.0.1:${gitea_webport}:3000"
|
||||
extra_hosts:
|
||||
- "host.docker.internal:host-gateway"
|
||||
environment:
|
||||
- USER_UID=1000
|
||||
- USER_GID=1000
|
||||
- GITEA__server__ROOT_URL=${gitea_rooturl}
|
||||
- GITEA__server__DOMAIN=${gitea_domain}
|
||||
- GITEA__server__SSH_DOMAIN=${gitea_domain}
|
||||
- GITEA__database__DB_TYPE=${gitea_dbtype}
|
||||
- GITEA__database__HOST=${gitea_dbhost}
|
||||
- GITEA__database__NAME=${gitea_dbname}
|
||||
- GITEA__database__USER=${gitea_dbuser}
|
||||
- GITEA__database__PASSWD=${gitea_dbpass}
|
||||
- GITEA__service__DISABLE_REGISTRATION=${gitea_disable_registration}
|
||||
volumes:
|
||||
- {{ gitea_volume }}:/data
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
|
Loading…
Reference in New Issue
Block a user