Formulaire de génération d'une application Yunohost

{{ main_form.hidden_tag() }} {{ main_form.generator_mode.label }} {{ main_form.generator_mode() }} {# TODO : this doesn't work, should be changed on the fly. Is it worth the trouble ? {% if main_form.generator_mode %} L'application générée contiendra des commentaires additionnels pour faciliter la compréhension {% else %} L'application générée ne contiendra que le minimum nécessaire {% endif %}
#}
En mode tutoriel, l'application générée contiendra des commentaires additionnels pour faciliter la compréhension. En version épurée, l'application générée ne contiendra que le minimum nécessaire.

Informations générales

{{ main_form.app_name.label }} {{ main_form.app_name()}}
{{ main_form.app_id.label}} {{ main_form.app_id() }}
{{ main_form.description_en.label}} {{ main_form.description_en(style="height: 2.5em;min-height: 2em; max-height: 4em;flex-grow: 1;box-sizing: border-box;")}}

{{ main_form.description_fr.label}} {{ main_form.description_fr(style=" height: 2.5em;min-height: 1em; max-height: 4em;flex-grow: 1;box-sizing: border-box;")}}

Informations sur l'upstream

Le terme upstream désigne le projet original qui maintient l'app

{{ main_form.license.label}} {{ main_form.license()}}
{{ main_form.website.label}} {{ main_form.website()}}
{{ main_form.demo.label}} {{ main_form.demo()}}
{{ main_form.admindoc.label}} {{ main_form.admindoc()}}
{{ main_form.userdoc.label}} {{ main_form.userdoc()}}
{{ main_form.code.label}} {{ main_form.code()}}

Informations sur le paquet et l'intégration dans YunoHost

{{ main_form.version.label}} {{ main_form.version()}}
{{ main_form.maintainers.label}} {{ main_form.maintainers(style="width: 60%;")}}
{{ main_form.multi_instance.label}} {{ main_form.multi_instance()}}
{{ main_form.architectures.label}} {{ main_form.architectures()}}

{{ main_form.ldap.label}} {{ main_form.ldap()}}
{{ main_form.sso.label}} {{ main_form.sso()}}

Questions à poser pendant l'installation

Cette partie sert à indiquer les questions qui devront être posées.
NB: seules des questions standard sont proposées ici, il faudra éventuellement compléter à la main en suivant le modèle des autres questions.

{{ main_form.domain_and_path.label}} {{ main_form.domain_and_path()}}
{{ main_form.init_main_permission.label}} {{ main_form.init_main_permission()}}
{{ main_form.init_admin_permission.label}} {{ main_form.init_admin_permission()}}
{{ main_form.language.label}} {{ main_form.language()}}

Ressources à initialiser

Il s'agit d'éléments techniques configurés avant que le "vrai" script d'install de l'app ne soit lancé. Typiquement : créer un user système, télécharger les sources de l'app, initialiser le dossier d'install et de données, installer des dépendances avec apt, créer une base de donnée SQL, ...

Sources du logiciel
{{ main_form.source_url.label}} {{ main_form.source_url()}}
{{ main_form.sha256sum.label}} {{ main_form.sha256sum()}}
{{ main_form.auto_update.label}} {{ main_form.auto_update()}}
{{ main_form.system_user.label}} {{ main_form.system_user()}}
{{ main_form.install_dir.label}} {{ main_form.install_dir()}}
{{ main_form.data_dir.label}} {{ main_form.data_dir()}}
{{ main_form.apt_dependencies.label}} {{ main_form.apt_dependencies(style="width:40%;")}}
{{ main_form.ports.label}} {{ main_form.ports()}}
{{ main_form.database.label }} {{ main_form.database() }}

Technologies spécifiques (to be reworked)

{{ main_form.supports_change_url.label}} {{ main_form.supports_change_url()}}
{{ main_form.use_logrotate.label}} {{ main_form.use_logrotate()}}
{{ main_form.use_fail2ban.label}} {{ main_form.use_fail2ban(onchange="showForm(this, 'fail2ban')")}} {%- if parameters['use_fail2ban'] == True -%} {# Not shown by default, so we show it if needed #} {%- else -%} {%- endif -%}
Configuration pour fail2ban {{ main_form.fail2ban_regex.label}} {{ main_form.fail2ban_regex(style="width:60%;")}}

{{ main_form.use_cron.label }} {{ main_form.use_cron(onchange="showForm(this, 'cron')") }} {%- if parameters['use_cron'] == True -%} {# Not shown by default, so we show it if needed #} {%- else -%} {%- endif -%}
Configuration pour CRON {{ main_form.cron_config_file.label}} {{ main_form.cron_config_file()}}

Configuration pour le serveur NGINX {{ main_form.nginx_config_file.label }}
{{ main_form.nginx_config_file() }}

{{ main_form.use_systemd_service.label}} {{ main_form.use_systemd_service(onchange="showForm(this, 'SystemD')")}}
{%- if parameters['use_systemd_service'] == True -%} {# Not shown by default, so we show it if needed #} {%- else -%} {%- endif -%}
Configuration pour le service SystemD {{ main_form.systemd_service_description.label }} {{ main_form.systemd_service_description() }}
{{ main_form.systemd_config_file.label }}
{{ main_form.systemd_config_file() }}

{{ main_form.use_custom_config_file.label}} {{ main_form.use_custom_config_file(onchange="showForm(this, 'custom_config')")}}
{%- if parameters['use_custom_config_file'] == True -%} {# Not shown by default, so we show it if needed #} {%- else -%} {%- endif -%}
Fichier de configuration personnalisé {{ main_form.custom_config_file.label }} {{ main_form.custom_config_file() }}
{{ main_form.custom_config_file_content.label }}
{{ main_form.custom_config_file_content() }}

Utilisation de PHP

{{ main_form.use_php.label}} {{ main_form.use_php(onchange="showForm(this, 'PHP')") }}
{%- if parameters['use_php'] == True -%} {# Not shown by default, so we show it if needed #} {%- else -%} {%- endif -%}
Fichier de configuration pour PHP {{ main_form.php_config_file.label }} {{ main_form.php_config_file()}}
{{ main_form.php_config_file_content.label }} {{ main_form.php_config_file_content()}}

Utilisation de NodeJS

{{ main_form.use_nodejs.label}} {{ main_form.use_nodejs(onchange="showForm(this, 'NodeJS')") }}
{%- if parameters['use_nodejs'] == True -%} {# Not shown by default, so we show it if needed #} {%- else -%} {%- endif -%}
Configuration pour NodeJS {{ main_form.use_nodejs_version.label}} {{ main_form.use_nodejs_version() }}
{{ main_form.use_nodejs_needs_yarn.label}} {{ main_form.use_nodejs_needs_yarn() }}

Utilisation de Python

{{ main_form.use_python.label}} {{ main_form.use_python(onchange="showForm(this, 'Python')") }}
{%- if parameters['use_python'] == True -%} {# Not shown by default, so we show it if needed #} {%- else -%} {%- endif -%}
Configuration pour Python {{ main_form.python_dependencies_type.label}} {{ main_form.python_dependencies_type(onchange="showForm(this, 'Python_dependencies')") }}
{%- if parameters['python_dependencies_type'] == 'requirements.txt' -%} {{ main_form.python_requirements.label}} {{ main_form.python_requirements() }} {%- else -%} {{ main_form.python_dependencies_list.label}} {{ main_form.python_dependencies_list() }} {%- endif -%}

{{ main_form.submit(class="btn btn-primary btn-sm btn-center") }} {% if parameters['invalid_form'] %}

Formulaire invalide, veuillez vérifier quel champ contient une erreur svp.

{% endif %}

{% if parameters['preview'] %} {# is defined #}
Afficher le code des fichiers principaux

Voici le code de l'application {{parameters['app.name']}}

Manifeste (manifest.toml)


{% set lines = template_manifest_content.splitlines() %}
{% for line in lines %} {{ line }}
{% endfor %}

Script d'installation (install)


{% set lines = template_install_content.splitlines() %}
{% for line in lines %} {{ line }}
{% endfor %}

Script de suppression (remove)


{% set lines = template_remove_content.splitlines() %}
{% for line in lines %} {{ line }}
{% endfor %}

Script de sauvegarde (backup)


{% set lines = template_backup_content.splitlines() %}
{% for line in lines %} {{ line }}
{% endfor %}

Script de restauration (restore)


{% set lines = template_restore_content.splitlines() %}
{% for line in lines %} {{ line }}
{% endfor %}

Script de mise à jour (upgrade)


{% set lines = template_upgrade_content.splitlines() %}
{% for line in lines %} {{ line }}
{% endfor %}

Script de configuration spéciale (config)


{% set lines = template_config_content.splitlines() %}
{% for line in lines %} {{ line }}
{% endfor %}

{%- if template_change_url_content -%}

Script de changement d'URL (change_url)


{% set lines = template_change_url_content.splitlines() %}
{% for line in lines %} {{ line }}
{% endfor %}

{% endif %} {%- if systemd_config_file -%}

Fichier de configuration du service SystemD (systemd.service)

            
            {{parameters['systemd_config_file']}}
            
        
{% endif %} {%- if nginx_config_file -%}

Fichier de configuration de NGINX (nginx.conf)

            
            {{parameters['nginx_config_file']}}
            
        
{% endif %} {%- if custom_config_file -%}

Fichier de configuration personnalisé ({{custom_config_file}})

            
            {{parameters['custom_config_file_content']}}
            
        
{% endif %} {%- if cron_config_file -%}

Fichier de configuration de tâche CRON (task.cron)

            
            {{parameters['cron_config_file']}}
            
        
{% endif %}

{% endif %}