mirror of
https://github.com/YunoHost-Apps/tiki_ynh.git
synced 2024-09-04 01:15:54 +02:00
v2
This commit is contained in:
parent
90adf419ac
commit
7c13cfbe10
7 changed files with 17 additions and 122 deletions
|
@ -7,7 +7,7 @@ location __PATH__/ {
|
||||||
index index.php;
|
index index.php;
|
||||||
|
|
||||||
# Common parameter to increase upload size limit in conjunction with dedicated php-fpm file
|
# Common parameter to increase upload size limit in conjunction with dedicated php-fpm file
|
||||||
#client_max_body_size 50M;
|
client_max_body_size 50M;
|
||||||
|
|
||||||
try_files $uri $uri/ index.php;
|
try_files $uri $uri/ index.php;
|
||||||
location ~ [^/]\.php(/|$) {
|
location ~ [^/]\.php(/|$) {
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
### Postinstall
|
|
||||||
|
|
||||||
You can log in using the special `admin` username and the `admin` password. You will be asked to change the password immediately after login.
|
|
||||||
|
|
||||||
### Storing your uploaded files
|
### Storing your uploaded files
|
||||||
|
|
||||||
To ease the install process and first access, Tiki saves your uploaded files (office documents, images, pdf, etc. attached to wiki pages, forum posts, tracker items, file galleries, ...) by default in its database. This works perfectly in most cases but it is not the recommended setup if you need to save many thousands of files or more.
|
To ease the install process and first access, Tiki saves your uploaded files (office documents, images, pdf, etc. attached to wiki pages, forum posts, tracker items, file galleries, ...) by default in its database. This works perfectly in most cases but it is not the recommended setup if you need to save many thousands of files or more.
|
1
doc/POST_INSTALL.md
Normal file
1
doc/POST_INSTALL.md
Normal file
|
@ -0,0 +1 @@
|
||||||
|
You can log in using the special `admin` username and the `admin` password. You will be asked to change the password immediately after login.
|
|
@ -15,26 +15,21 @@ website = "https://tiki.org/"
|
||||||
demo = "https://tiki.org/Try-Tiki"
|
demo = "https://tiki.org/Try-Tiki"
|
||||||
admindoc = "https://doc.tiki.org"
|
admindoc = "https://doc.tiki.org"
|
||||||
code = "https://gitlab.com/tikiwiki/tiki/"
|
code = "https://gitlab.com/tikiwiki/tiki/"
|
||||||
cpe = "???" # FIXME: optional but recommended if relevant, this is meant to contain the Common Platform Enumeration, which is sort of a standard id for applications defined by the NIST. In particular, Yunohost may use this is in the future to easily track CVE (=security reports) related to apps. The CPE may be obtained by searching here: https://nvd.nist.gov/products/cpe/search. For example, for Nextcloud, the CPE is 'cpe:2.3:a:nextcloud:nextcloud' (no need to include the version number)
|
|
||||||
fund = "???" # FIXME: optional but recommended (or remove if irrelevant / not applicable). This is meant to be an URL where people can financially support this app, especially when its development is based on volunteers and/or financed by its community. YunoHost may later advertise it in the webadmin.
|
|
||||||
|
|
||||||
[integration]
|
[integration]
|
||||||
yunohost = ">= 11.0.9"
|
yunohost = ">= 11.1.12"
|
||||||
architectures = "all" # FIXME: can be replaced by a list of supported archs using the dpkg --print-architecture nomenclature (amd64/i386/armhf/arm64), for example: ["amd64", "i386"]
|
architectures = "all"
|
||||||
multi_instance = true
|
multi_instance = true
|
||||||
ldap = "?" # FIXME: replace with true, false, or "not_relevant". Not to confuse with the "sso" key : the "ldap" key corresponds to wether or not a user *can* login on the app using its YunoHost credentials.
|
ldap = "?"
|
||||||
sso = "?" # FIXME: replace with true, false, or "not_relevant". Not to confuse with the "ldap" key : the "sso" key corresponds to wether or not a user is *automatically logged-in* on the app when logged-in on the YunoHost portal.
|
sso = "?"
|
||||||
disk = "50M" # FIXME: replace with an **estimate** minimum disk requirement. e.g. 20M, 400M, 1G, ...
|
disk = "50M"
|
||||||
ram.build = "50M" # FIXME: replace with an **estimate** minimum ram requirement. e.g. 50M, 400M, 1G, ...
|
ram.build = "50M"
|
||||||
ram.runtime = "50M" # FIXME: replace with an **estimate** minimum ram requirement. e.g. 50M, 400M, 1G, ...
|
ram.runtime = "50M"
|
||||||
|
|
||||||
[install]
|
[install]
|
||||||
[install.domain]
|
[install.domain]
|
||||||
# this is a generic question - ask strings are automatically handled by Yunohost's core
|
|
||||||
type = "domain"
|
type = "domain"
|
||||||
|
|
||||||
[install.path]
|
[install.path]
|
||||||
# this is a generic question - ask strings are automatically handled by Yunohost's core
|
|
||||||
type = "path"
|
type = "path"
|
||||||
default = "/tiki"
|
default = "/tiki"
|
||||||
|
|
||||||
|
@ -52,5 +47,8 @@ ram.runtime = "50M" # FIXME: replace with an **estimate** minimum ram requiremen
|
||||||
[resources.permissions]
|
[resources.permissions]
|
||||||
main.url = "/"
|
main.url = "/"
|
||||||
|
|
||||||
|
[resources.apt]
|
||||||
|
packages = "php7.4-bz2 php7.4-curl php7.4-gd php7.4-zip php7.4-mysql php7.4-xml php7.4-mbstring"
|
||||||
|
|
||||||
[resources.database]
|
[resources.database]
|
||||||
type = "mysql"
|
type = "mysql"
|
||||||
|
|
110
scripts/install
110
scripts/install
|
@ -9,82 +9,14 @@
|
||||||
source _common.sh
|
source _common.sh
|
||||||
source /usr/share/yunohost/helpers
|
source /usr/share/yunohost/helpers
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# MANAGE SCRIPT FAILURE
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
#REMOVEME? ynh_clean_setup () {
|
|
||||||
### Remove this function if there's nothing to clean before calling the remove script.
|
|
||||||
true
|
|
||||||
}
|
|
||||||
# Exit if an error occurs during the execution of the script
|
|
||||||
#REMOVEME? ynh_abort_if_errors
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# RETRIEVE ARGUMENTS FROM THE MANIFEST
|
|
||||||
#=================================================
|
|
||||||
|
|
||||||
#REMOVEME? domain=$YNH_APP_ARG_DOMAIN
|
|
||||||
#REMOVEME? path=$YNH_APP_ARG_PATH
|
|
||||||
#REMOVEME? is_public=$YNH_APP_ARG_IS_PUBLIC
|
|
||||||
phpversion=$YNH_PHP_VERSION
|
|
||||||
|
|
||||||
#REMOVEME? app=$YNH_APP_INSTANCE_NAME
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# CHECK IF THE APP CAN BE INSTALLED WITH THESE ARGS
|
|
||||||
#=================================================
|
|
||||||
#REMOVEME? ynh_script_progression --message="Validating installation parameters..." --weight=1
|
|
||||||
|
|
||||||
#REMOVEME? install_dir=/var/www/$app
|
|
||||||
#REMOVEME? test ! -e "$install_dir" || ynh_die --message="This path already contains a folder"
|
|
||||||
|
|
||||||
# Register (book) web path
|
|
||||||
#REMOVEME? ynh_webpath_register --app=$app --domain=$domain --path=$path
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# STORE SETTINGS FROM MANIFEST
|
|
||||||
#=================================================
|
|
||||||
#REMOVEME? ynh_script_progression --message="Storing installation settings..." --weight=1
|
|
||||||
|
|
||||||
#REMOVEME? ynh_app_setting_set --app=$app --key=domain --value=$domain
|
|
||||||
#REMOVEME? ynh_app_setting_set --app=$app --key=path --value=$path
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# INSTALL DEPENDENCIES
|
|
||||||
#=================================================
|
|
||||||
#REMOVEME? ynh_script_progression --message="Installing dependencies..." --weight=1
|
|
||||||
|
|
||||||
#REMOVEME? ynh_install_app_dependencies $pkg_dependencies
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# CREATE DEDICATED USER
|
|
||||||
#=================================================
|
|
||||||
#REMOVEME? ynh_script_progression --message="Configuring system user..." --weight=1
|
|
||||||
|
|
||||||
# Create a system user
|
|
||||||
#REMOVEME? ynh_system_user_create --username=$app --home_dir="$install_dir"
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# CREATE A MYSQL DATABASE
|
|
||||||
#=================================================
|
|
||||||
#REMOVEME? ynh_script_progression --message="Creating a MySQL database..." --weight=3
|
|
||||||
|
|
||||||
#REMOVEME? db_name=$(ynh_sanitize_dbid --db_name=$app)
|
|
||||||
#REMOVEME? db_user=$db_name
|
|
||||||
#REMOVEME? ynh_app_setting_set --app=$app --key=db_name --value=$db_name
|
|
||||||
#REMOVEME? ynh_mysql_setup_db --db_user=$db_user --db_name=$db_name
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
# DOWNLOAD, CHECK AND UNPACK SOURCE
|
||||||
#=================================================
|
#=================================================
|
||||||
ynh_script_progression --message="Setting up source files..." --weight=15
|
ynh_script_progression --message="Setting up source files..." --weight=15
|
||||||
|
|
||||||
#REMOVEME? ynh_app_setting_set --app=$app --key=install_dir --value=$install_dir
|
|
||||||
# Download, check integrity, uncompress and patch the source from app.src
|
# Download, check integrity, uncompress and patch the source from app.src
|
||||||
ynh_setup_source --dest_dir="$install_dir"
|
ynh_setup_source --dest_dir="$install_dir"
|
||||||
|
|
||||||
chmod 750 "$install_dir"
|
|
||||||
chmod -R o-rwx "$install_dir"
|
chmod -R o-rwx "$install_dir"
|
||||||
chown -R $app:www-data "$install_dir"
|
chown -R $app:www-data "$install_dir"
|
||||||
|
|
||||||
|
@ -104,20 +36,6 @@ ynh_script_progression --message="Configuring PHP-FPM..." --weight=1
|
||||||
# Create a dedicated PHP-FPM config
|
# Create a dedicated PHP-FPM config
|
||||||
ynh_add_fpm_config
|
ynh_add_fpm_config
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# CREATE DATA DIRECTORY
|
|
||||||
#=================================================
|
|
||||||
ynh_script_progression --message="Creating a data directory..." --weight=1
|
|
||||||
|
|
||||||
#REMOVEME? data_dir=/home/yunohost.app/$app
|
|
||||||
#REMOVEME? ynh_app_setting_set --app=$app --key=data_dir --value=$data_dir
|
|
||||||
|
|
||||||
mkdir -p $data_dir
|
|
||||||
|
|
||||||
chmod 750 "$data_dir"
|
|
||||||
chmod -R o-rwx "$data_dir"
|
|
||||||
chown -R $app:www-data "$data_dir"
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# ADD INITIAL CONFIGURATION
|
# ADD INITIAL CONFIGURATION
|
||||||
#=================================================
|
#=================================================
|
||||||
|
@ -128,39 +46,21 @@ exec_as_app() {
|
||||||
php${phpversion} --define apc.enable_cli=1 "$@")
|
php${phpversion} --define apc.enable_cli=1 "$@")
|
||||||
}
|
}
|
||||||
|
|
||||||
ynh_script_progression --message="Create database configuration file..." --time --weight=1
|
ynh_script_progression --message="Create database configuration file..." --weight=1
|
||||||
exec_as_app console.php database:configure "$app" "$db_pwd" "$app"
|
exec_as_app console.php database:configure "$app" "$db_pwd" "$app"
|
||||||
|
|
||||||
ynh_script_progression --message="Create database contents..." --time --weight=1
|
ynh_script_progression --message="Create database contents..." --weight=1
|
||||||
exec_as_app console.php database:install
|
exec_as_app console.php database:install
|
||||||
|
|
||||||
ynh_script_progression --message="Lock installer..." --time --weight=1
|
ynh_script_progression --message="Lock installer..." --weight=1
|
||||||
exec_as_app console.php installer:lock
|
exec_as_app console.php installer:lock
|
||||||
|
|
||||||
ynh_script_progression --message="Create data index..." --time --weight=1
|
ynh_script_progression --message="Create data index..." --weight=1
|
||||||
exec_as_app console.php index:rebuild
|
exec_as_app console.php index:rebuild
|
||||||
|
|
||||||
ynh_script_progression --message="Set on Long Term Support versions..." --time --weight=1
|
ynh_script_progression --message="Set on Long Term Support versions..." --weight=1
|
||||||
exec_as_app console.php preferences:set tiki_release_cycle longterm
|
exec_as_app console.php preferences:set tiki_release_cycle longterm
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# SETUP SSOWAT
|
|
||||||
#=================================================
|
|
||||||
#REMOVEME? ynh_script_progression --message="Configuring permissions..." --weight=1
|
|
||||||
|
|
||||||
# Make app public if necessary
|
|
||||||
#REMOVEME? if [ $is_public -eq 1 ]
|
|
||||||
then
|
|
||||||
#REMOVEME? ynh_permission_update --permission="main" --add="visitors"
|
|
||||||
fi
|
|
||||||
|
|
||||||
#=================================================
|
|
||||||
# RELOAD NGINX
|
|
||||||
#=================================================
|
|
||||||
#REMOVEME? ynh_script_progression --message="Reloading NGINX web server..." --weight=1
|
|
||||||
|
|
||||||
#REMOVEME? ynh_systemd_action --service_name=nginx --action=reload
|
|
||||||
|
|
||||||
#=================================================
|
#=================================================
|
||||||
# END OF SCRIPT
|
# END OF SCRIPT
|
||||||
#=================================================
|
#=================================================
|
||||||
|
|
0
tests.toml
Normal file
0
tests.toml
Normal file
Loading…
Reference in a new issue