Better config loading
This commit is contained in:
parent
6d2feaf079
commit
bd7025831d
@ -83,6 +83,7 @@
|
||||
app: gitea
|
||||
restart: false
|
||||
config:
|
||||
APP_NAME: "{{ autonomic_app_name }}"
|
||||
ADMIN_MAIL: "{{ autonomic_admin_mail }}"
|
||||
ADMIN_PASS: "{{ autonomic_admin_pass }}"
|
||||
ADMIN_USER: "{{ autonomic_admin_user }}"
|
||||
@ -95,6 +96,8 @@
|
||||
DOKKU_LETSENCRYPT_EMAIL: "{{ autonomic_admin_mail }}"
|
||||
DOMAIN: "git.autonomic.zone"
|
||||
INSTALL_LOCK: "true"
|
||||
JWT_SECRET: "{{ jwt_secret }}"
|
||||
RUN_MODE: "prod"
|
||||
SECRET_KEY: "{{ secret_key}}"
|
||||
USER_GID: "{{ gitea_user_guid }}"
|
||||
USER_UID: "{{ gitea_user_uid }}"
|
||||
|
@ -1,3 +1,4 @@
|
||||
---
|
||||
autonomic_app_name: "Gitea: Git with solidaritea"
|
||||
autonomic_admin_mail: helo@autonomic.zone
|
||||
autonomic_admin_user: autonomic
|
||||
|
@ -44,6 +44,9 @@ setup_app_ini() {
|
||||
|
||||
echo "-----> Using crudini to setup configuration"
|
||||
|
||||
crudini --set "$app_ini" APP_NAME "${APP_NAME}"
|
||||
crudini --set "$app_ini" RUN_MODE "${RUN_MODE}"
|
||||
|
||||
crudini --del "$app_ini" database PATH
|
||||
crudini --set "$app_ini" database DB_TYPE mysql
|
||||
crudini --set "$app_ini" database HOST "${DB_HOST}"
|
||||
@ -55,9 +58,15 @@ setup_app_ini() {
|
||||
crudini --set "$app_ini" server PROTOCOL "http"
|
||||
crudini --set "$app_ini" server DOMAIN "${DOMAIN}"
|
||||
crudini --set "$app_ini" server ROOT_URL "https://%(DOMAIN)s/"
|
||||
crudini --set "$app_ini" sserver HTTP_ADDR ""
|
||||
crudini --set "$app_ini" sserver HTTP_PORT "3000"
|
||||
crudini --set "$app_ini" server HTTP_ADDR ""
|
||||
crudini --set "$app_ini" server HTTP_PORT "3000"
|
||||
|
||||
crudini --set "$app_ini" service DISABLE_REGISTRATION "${DISABLE_REGISTRATION}"
|
||||
|
||||
crudini --set "$app_ini" security INSTALL_LOCK "${INSTALL_LOCK}"
|
||||
crudini --set "$app_ini" security SECRET_KEY "${SECRET_KEY}"
|
||||
|
||||
crudini --set "$app_ini" oauth2 JWT_SECRET "${JWT_SECRET}"
|
||||
}
|
||||
|
||||
main() {
|
||||
|
Reference in New Issue
Block a user