eole-gitea/tmpl/gitea-db.yml

41 lines
1022 B
YAML
Raw Normal View History

---
%set dmode = %%getVar('gitea_db_mode','non')
%if %%dmode == "externe"
dbhost: %%gitea_dbserver
dbport: %%gitea_dbport
dbroot: %%gitea_dbuser
dbrootpwd: %%gitea_dbpass
%else if %%dmode == "local"
dbhost: 127.0.0.1
%end if
dbtype: mysql
dbname: gitea
dbuser: gitea
dbpass: "changeme"
%set allow_hosts = %%getVar('gitea_allow_hosts', '')
%if %%dmode == "local"
client_hosts: ["127.0.0.1", "localhost" %slurp
%else if %%dmode == "externe"
client_hosts: ["%%adresse_ip_eth0" %slurp
%end if
%if %%dmode != "default"
%if %%is_empty(%%allow_hosts)
]
%else
%for %%hst in %%allow_hosts
,"%%hst" %slurp
%end for
]
%end if
%end if
createscript: "/usr/share/eole/db/gitea/gen/00-create-gitea-db.sql"
#updatescripts: ["/usr/share/eole/db/gitea/updates/gitea-update-1.sql"]
%set cnt_prefix = %%getVar('container_path_reseau', '')
pwd_files:
- {file: '%%cnt_prefix/etc/gitea/conf/app.ini',
pattern: 'PASSWD = `',
end_pattern: '`',
2018-10-30 16:32:58 +01:00
owner: 'root:gitservice',
mod: '660' }