1
0
Fork 0
mirror of https://github.com/YunoHost-Apps/gitlab_ynh.git synced 2024-09-03 18:36:35 +02:00

Merge pull request #136 from YunoHost-Apps/testing

13.7.0
This commit is contained in:
Kayou 2020-12-28 15:12:24 +01:00 committed by GitHub
commit b40ba1a874
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
14 changed files with 91 additions and 65 deletions

View file

@ -1,7 +1,7 @@
# GitLab for YunoHost # GitLab for YunoHost
[![Integration level](https://dash.yunohost.org/integration/gitlab.svg)](https://dash.yunohost.org/appci/app/gitlab) ![](https://ci-apps.yunohost.org/ci/badges/gitlab.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/gitlab.maintain.svg) [![Integration level](https://dash.yunohost.org/integration/gitlab.svg)](https://dash.yunohost.org/appci/app/gitlab) ![](https://ci-apps.yunohost.org/ci/badges/gitlab.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/gitlab.maintain.svg)
[![Install GitLab with YunoHost](https://install-app.yunohost.org/install-with-yunohost.png)](https://install-app.yunohost.org/?app=gitlab) [![Install GitLab with YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=gitlab)
*[Lire ce readme en français.](./README_fr.md)* *[Lire ce readme en français.](./README_fr.md)*
@ -12,7 +12,7 @@ If you don't have YunoHost, please see [here](https://yunohost.org/#/install) to
GitLab is a web-based Git-repository manager providing wiki, issue-tracking and CI/CD pipeline features, using an open-source license, developed by GitLab Inc. GitLab is a web-based Git-repository manager providing wiki, issue-tracking and CI/CD pipeline features, using an open-source license, developed by GitLab Inc.
**Shipped version:** 13.6.3 **Shipped version:** 13.7.0
## Screenshots ## Screenshots
@ -55,8 +55,7 @@ How to configure GitLab:
--- ---
Developers info ## Developers info
----------------
Please do your pull request to the [testing branch](https://github.com/YunoHost-Apps/gitlab_ynh/tree/testing). Please do your pull request to the [testing branch](https://github.com/YunoHost-Apps/gitlab_ynh/tree/testing).

View file

@ -1,7 +1,7 @@
# GitLab pour YunoHost # GitLab pour YunoHost
[![Integration level](https://dash.yunohost.org/integration/gitlab.svg)](https://dash.yunohost.org/appci/app/gitlab) ![](https://ci-apps.yunohost.org/ci/badges/gitlab.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/gitlab.maintain.svg) [![Integration level](https://dash.yunohost.org/integration/gitlab.svg)](https://dash.yunohost.org/appci/app/gitlab) ![](https://ci-apps.yunohost.org/ci/badges/gitlab.status.svg) ![](https://ci-apps.yunohost.org/ci/badges/gitlab.maintain.svg)
[![Installer GitLab pour YunoHost](https://install-app.yunohost.org/install-with-yunohost.png)](https://install-app.yunohost.org/?app=gitlab) [![Installer GitLab pour YunoHost](https://install-app.yunohost.org/install-with-yunohost.svg)](https://install-app.yunohost.org/?app=gitlab)
*[Read this readme in english.](./README.md)* *[Read this readme in english.](./README.md)*
@ -12,7 +12,7 @@ Si vous n'avez pas YunoHost, regardez [ici](https://yunohost.org/#/install) pour
GitLab est un gestionnaire Web de dépôt Git fournissant des fonctionnalités de wiki, de rapports de bugs et de pipeline CI/CD. GitLab est une application open source développée par GitLab Inc. GitLab est un gestionnaire Web de dépôt Git fournissant des fonctionnalités de wiki, de rapports de bugs et de pipeline CI/CD. GitLab est une application open source développée par GitLab Inc.
**Version incluse :** 13.6.3 **Version incluse :** 13.7.0
## Captures d'écran ## Captures d'écran
@ -55,8 +55,7 @@ Comment configurer GitLab :
--- ---
Informations pour les développeurs ## Informations pour les développeurs
----------------
Merci de faire vos pull request sur la [branche testing](https://github.com/YunoHost-Apps/gitlab_ynh/tree/testing). Merci de faire vos pull request sur la [branche testing](https://github.com/YunoHost-Apps/gitlab_ynh/tree/testing).

View file

@ -21,8 +21,6 @@
multi_instance=0 multi_instance=0
port_already_use=1 (8080) port_already_use=1 (8080)
change_url=1 change_url=1
;;; Levels
Level 5=auto
;;; Options ;;; Options
Email= Email=
Notification=none Notification=none

View file

@ -3,4 +3,4 @@ SOURCE_SUM=__SHA256_SUM__
SOURCE_SUM_PRG=sha256sum SOURCE_SUM_PRG=sha256sum
SOURCE_FILENAME=__SOURCE_FILENAME__ SOURCE_FILENAME=__SOURCE_FILENAME__
SOURCE_EXTRACT=false SOURCE_EXTRACT=false
SOURCE_FORMAT=deb SOURCE_FORMAT=deb

View file

@ -555,6 +555,11 @@ EOS
# gitlab_rails['forti_authenticator_username'] = 'admin' # gitlab_rails['forti_authenticator_username'] = 'admin'
# gitlab_rails['forti_authenticator_access_token'] = 's3cr3t' # gitlab_rails['forti_authenticator_access_token'] = 's3cr3t'
### FortiToken Cloud authentication settings
# gitlab_rails['forti_token_cloud_enabled'] = false
# gitlab_rails['forti_token_cloud_client_id'] = 'forti_token_cloud_client_id'
# gitlab_rails['forti_token_cloud_client_secret'] = 's3cr3t'
### Backup Settings ### Backup Settings
###! Docs: https://docs.gitlab.com/omnibus/settings/backups.html ###! Docs: https://docs.gitlab.com/omnibus/settings/backups.html
@ -637,8 +642,8 @@ gitlab_rails['gitlab_shell_ssh_port'] = __SSH_PORT__
### Extra customization ### Extra customization
# gitlab_rails['extra_google_analytics_id'] = '_your_tracking_id' # gitlab_rails['extra_google_analytics_id'] = '_your_tracking_id'
# gitlab_rails['extra_google_tag_manager_id'] = '_your_tracking_id' # gitlab_rails['extra_google_tag_manager_id'] = '_your_tracking_id'
# gitlab_rails['extra_piwik_url'] = '_your_piwik_url' # gitlab_rails['extra_matomo_url'] = '_your_matomo_url'
# gitlab_rails['extra_piwik_site_id'] = '_your_piwik_site_id' # gitlab_rails['extra_matomo_site_id'] = '_your_matomo_site_id'
##! Docs: https://docs.gitlab.com/omnibus/settings/environment-variables.html ##! Docs: https://docs.gitlab.com/omnibus/settings/environment-variables.html
# gitlab_rails['env'] = { # gitlab_rails['env'] = {
@ -696,6 +701,12 @@ gitlab_rails['gitlab_shell_ssh_port'] = __SSH_PORT__
# gitlab_rails['db_prepared_statements'] = false # gitlab_rails['db_prepared_statements'] = false
# gitlab_rails['db_statements_limit'] = 1000 # gitlab_rails['db_statements_limit'] = 1000
# gitlab_rails['db_connect_timeout'] = nil # gitlab_rails['db_connect_timeout'] = nil
# gitlab_rails['db_keepalives'] = nil
# gitlab_rails['db_keepalives_idle'] = nil
# gitlab_rails['db_keepalives_interval'] = nil
# gitlab_rails['db_keepalives_count'] = nil
# gitlab_rails['db_tcp_user_timeout'] = nil
# gitlab_rails['db_application_name'] = nil
### GitLab Redis settings ### GitLab Redis settings
@ -1513,6 +1524,9 @@ nginx['listen_https'] = false
##! Configure to expose GitLab Pages on external IP address, serving the HTTPS ##! Configure to expose GitLab Pages on external IP address, serving the HTTPS
# gitlab_pages['external_https'] = [] # gitlab_pages['external_https'] = []
##! Configure to expose GitLab Pages on external IP address, serving the HTTPS over PROXYv2
# gitlab_pages['external_https_proxyv2'] = []
##! Configure to use the default list of cipher suites ##! Configure to use the default list of cipher suites
# gitlab_pages['insecure_ciphers'] = false # gitlab_pages['insecure_ciphers'] = false
@ -1583,6 +1597,19 @@ nginx['listen_https'] = false
##! Shared secret used for authentication between Pages and GitLab ##! Shared secret used for authentication between Pages and GitLab
# gitlab_pages['api_secret_key'] = nil # Will be generated if not set. Base64 encoded and exactly 32 bytes long. # gitlab_pages['api_secret_key'] = nil # Will be generated if not set. Base64 encoded and exactly 32 bytes long.
##! Advanced settings for serving GitLab Pages from zip archives.
##! The recommended default values are set inside GitLab Pages.
##! Should be changed only if absolutely needed.
##! The maximum time an archive will be cached in memory.
# gitlab_pages['zip_cache_expiration'] = "60s"
##! Zip archive cache cleaning interval.
# gitlab_pages['zip_cache_cleanup'] = "30s"
##! The interval to refresh a cache archive if accessed before expiring.
# gitlab_pages['zip_cache_refresh'] = "30s"
##! The maximum amount of time it takes to open a zip archive from the file system or object storage.
# gitlab_pages['zip_open_timeout'] = "30s"
# gitlab_pages['env_directory'] = "/opt/gitlab/etc/gitlab-pages/env" # gitlab_pages['env_directory'] = "/opt/gitlab/etc/gitlab-pages/env"
# gitlab_pages['env'] = { # gitlab_pages['env'] = {
# 'SSL_CERT_DIR' => "#{node['package']['install-dir']}/embedded/ssl/certs/" # 'SSL_CERT_DIR' => "#{node['package']['install-dir']}/embedded/ssl/certs/"
@ -2053,6 +2080,13 @@ nginx['listen_https'] = false
# gitaly['daily_maintenance_start_minute'] = 30 # gitaly['daily_maintenance_start_minute'] = 30
# gitaly['daily_maintenance_duration'] = '30m' # gitaly['daily_maintenance_duration'] = '30m'
# gitaly['daily_maintenance_storages'] = ["default"] # gitaly['daily_maintenance_storages'] = ["default"]
# gitaly['cgroups_count'] = 10
# gitaly['cgroups_mountpoint'] = '/sys/fs/cgroup'
# gitaly['cgroups_hierarchy_root'] = 'gitaly'
# gitaly['cgroups_memory_enabled'] = true
# gitaly['cgroups_memory_limit'] = 1048576
# gitaly['cgroups_cpu_enabled'] = true
# gitaly['cgroups_cpu_shares'] = 512
################################################################################ ################################################################################
## Praefect ## Praefect
@ -2178,6 +2212,7 @@ nginx['listen_https'] = false
# gitlab_rails['historical_data_worker_cron'] = "0 12 * * *" # gitlab_rails['historical_data_worker_cron'] = "0 12 * * *"
# gitlab_rails['pseudonymizer_worker_cron'] = "0 23 * * *" # gitlab_rails['pseudonymizer_worker_cron'] = "0 23 * * *"
# gitlab_rails['elastic_index_bulk_cron'] = "*/1 * * * *" # gitlab_rails['elastic_index_bulk_cron'] = "*/1 * * * *"
# gitlab_rails['analytics_devops_adoption_create_all_snapshots_worker_cron'] = "0 0 1 * *"
################################################################################ ################################################################################
## Kerberos (EE Only) ## Kerberos (EE Only)
@ -2217,8 +2252,8 @@ nginx['listen_https'] = false
# } # }
################################################################################ ################################################################################
## Dependency proxy (EE Only) ## Dependency proxy
##! Docs: https://docs.gitlab.com/ee/administration/dependency_proxy.md ##! Docs: https://docs.gitlab.com/ee/administration/packages/dependency_proxy.html
################################################################################ ################################################################################
# gitlab_rails['dependency_proxy_enabled'] = true # gitlab_rails['dependency_proxy_enabled'] = true
@ -2549,7 +2584,9 @@ nginx['listen_https'] = false
# patroni['maximum_lag_on_failover'] = 1_048_576 # patroni['maximum_lag_on_failover'] = 1_048_576
# patroni['max_timelines_history'] = 0 # patroni['max_timelines_history'] = 0
# patroni['master_start_timeout'] = 300 # patroni['master_start_timeout'] = 300
# patroni['use_pg_rewind'] = false # patroni['use_pg_rewind'] = true
# patroni['remove_data_directory_on_rewind_failure'] = false
# patroni['remove_data_directory_on_diverged_timelines'] = false
# patroni['use_slots'] = true # patroni['use_slots'] = true
# patroni['replication_password'] = nil # patroni['replication_password'] = nil
# patroni['replication_slots'] = {} # patroni['replication_slots'] = {}

View file

@ -3,4 +3,4 @@ SOURCE_SUM=__SHA256_SUM__
SOURCE_SUM_PRG=sha256sum SOURCE_SUM_PRG=sha256sum
SOURCE_FILENAME=__SOURCE_FILENAME__ SOURCE_FILENAME=__SOURCE_FILENAME__
SOURCE_EXTRACT=false SOURCE_EXTRACT=false
SOURCE_FORMAT=deb SOURCE_FORMAT=deb

View file

@ -2,7 +2,7 @@
"name": "GitLab", "name": "GitLab",
"id": "gitlab", "id": "gitlab",
"packaging_format": 1, "packaging_format": 1,
"version": "13.6.3~ynh1", "version": "13.7.0~ynh1",
"description": { "description": {
"en": "Git-repository manager.", "en": "Git-repository manager.",
"fr": "Gestionnaire de dépôts Git." "fr": "Gestionnaire de dépôts Git."

View file

@ -24,7 +24,7 @@ ynh_abort_if_errors
#================================================= #=================================================
# LOAD SETTINGS # LOAD SETTINGS
#================================================= #=================================================
ynh_script_progression --message="Loading installation settings..." --weight=1 ynh_print_info --message="Loading installation settings..."
app=$YNH_APP_INSTANCE_NAME app=$YNH_APP_INSTANCE_NAME
@ -32,18 +32,19 @@ config_path=$(ynh_app_setting_get --app=$app --key=config_path)
domain=$(ynh_app_setting_get --app=$app --key=domain) domain=$(ynh_app_setting_get --app=$app --key=domain)
#================================================= #=================================================
# STANDARD BACKUP STEPS # DECLARE DATA AND CONF FILES TO BACKUP
#=================================================
ynh_print_info --message="Declaring files to be backed up..."
#================================================= #=================================================
# BACKUP THE NGINX CONFIGURATION # BACKUP THE NGINX CONFIGURATION
#================================================= #=================================================
ynh_script_progression --message="Backing up nginx web server configuration..." --weight=1
ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf" ynh_backup --src_path="/etc/nginx/conf.d/$domain.d/$app.conf"
#================================================= #=================================================
# BACKUP GITLAB DATABASE # BACKUP GITLAB DATABASE
#================================================= #=================================================
ynh_script_progression --message="Backuping of Gitlab..." --weight=9
# Use gitlab-backup to backup # Use gitlab-backup to backup
# For the complete doc: https://docs.gitlab.com/ce/raketasks/backup_restore.html # For the complete doc: https://docs.gitlab.com/ce/raketasks/backup_restore.html
@ -55,7 +56,6 @@ ynh_backup --src_path="/var/opt/$app/backups/last_gitlab_backup.tar"
#================================================= #=================================================
# BACKUP CONF FILES # BACKUP CONF FILES
#================================================= #=================================================
ynh_script_progression --message="Backuping configuration files of Gitlab..." --weight=1
ynh_backup --src_path="$config_path/gitlab-secrets.json" ynh_backup --src_path="$config_path/gitlab-secrets.json"
ynh_backup --src_path="$config_path/gitlab.rb" ynh_backup --src_path="$config_path/gitlab.rb"
@ -65,4 +65,4 @@ ynh_backup --src_path="$config_path/gitlab-persistent.rb"
# END OF SCRIPT # END OF SCRIPT
#================================================= #=================================================
ynh_script_progression --message="Backup script completed for $app. (YunoHost will then actually copy those files to the archive)." --last ynh_print_info --message="Backup script completed for $app. (YunoHost will then actually copy those files to the archive)."

View file

@ -55,7 +55,7 @@ fi
#================================================= #=================================================
# MODIFY URL IN NGINX CONF # MODIFY URL IN NGINX CONF
#================================================= #=================================================
ynh_script_progression --message="Updating nginx web server configuration..." --weight=1 ynh_script_progression --message="Updating NGINX web server configuration..." --weight=1
nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf nginx_conf_path=/etc/nginx/conf.d/$old_domain.d/$app.conf
@ -92,7 +92,7 @@ fi
#================================================= #=================================================
# CONFIGURE GITLAB # CONFIGURE GITLAB
#================================================= #=================================================
ynh_script_progression --message="Configure gitlab..." --weight=28 ynh_script_progression --message="Configure GitLab..." --weight=28
ynh_backup_if_checksum_is_different --file="$config_path/gitlab.rb" ynh_backup_if_checksum_is_different --file="$config_path/gitlab.rb"
@ -125,7 +125,7 @@ gitlab-ctl reconfigure
#================================================= #=================================================
# WAITING GITLAB # WAITING GITLAB
#================================================= #=================================================
ynh_script_progression --message="Waiting for gitlab..." --weight=15 ynh_script_progression --message="Waiting for GitLab..." --weight=15
ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path="/var/log/$app/puma/current" --line_match="Listening on tcp://127.0.0.1:$portPuma" --timeout=300 ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path="/var/log/$app/puma/current" --line_match="Listening on tcp://127.0.0.1:$portPuma" --timeout=300
@ -134,7 +134,7 @@ ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path=
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX
#================================================= #=================================================
ynh_script_progression --message="Reloading nginx web server..." --weight=1 ynh_script_progression --message="Reloading NGINX web server..." --weight=1
ynh_systemd_action --action=reload --service_name=nginx ynh_systemd_action --action=reload --service_name=nginx
@ -142,4 +142,4 @@ ynh_systemd_action --action=reload --service_name=nginx
# END OF SCRIPT # END OF SCRIPT
#================================================= #=================================================
ynh_script_progression --message="Change of URL completed for $app" --last ynh_script_progression --message="Change of URL completed for GitLab" --last

View file

@ -148,7 +148,7 @@ fi
#================================================= #=================================================
# PRECONFIGURE GITLAB # PRECONFIGURE GITLAB
#================================================= #=================================================
ynh_script_progression --message="Preconfigure gitlab..." --weight=1 ynh_script_progression --message="Preconfigure GitLab..." --weight=1
mkdir -p $config_path mkdir -p $config_path
@ -177,7 +177,7 @@ ynh_store_file_checksum --file="$config_path/gitlab.rb"
#================================================= #=================================================
# DOWNLOAD, CHECK AND UNPACK SOURCE # DOWNLOAD, CHECK AND UNPACK SOURCE
#================================================= #=================================================
ynh_script_progression --message="Setting up source files..." --weight=200 ynh_script_progression --message="Setting up source files..." --weight=50
source ./upgrade.d/upgrade.last.sh source ./upgrade.d/upgrade.last.sh
cp ../conf/$architecture.src.default ../conf/$architecture.src cp ../conf/$architecture.src.default ../conf/$architecture.src
@ -199,9 +199,9 @@ fi
#================================================= #=================================================
# NGINX CONFIGURATION # NGINX CONFIGURATION
#================================================= #=================================================
ynh_script_progression --message="Configuring nginx web server..." --weight=2 ynh_script_progression --message="Configuring NGINX web server..." --weight=2
# Create a dedicated nginx config # Create a dedicated NGINX config
ynh_add_nginx_config client_max_body_size ynh_add_nginx_config client_max_body_size
#================================================= #=================================================
@ -224,7 +224,7 @@ ApplicationSetting.last.update_attributes(password_authentication_enabled_for_we
#================================================= #=================================================
# RECONFIGURE TO TAKE INTO ACCOUNT CHANGES # RECONFIGURE TO TAKE INTO ACCOUNT CHANGES
#================================================= #=================================================
ynh_script_progression --message="Reconfigure gitlab..." --weight=13 ynh_script_progression --message="Reconfigure GitLab..." --weight=13
gitlab-ctl reconfigure gitlab-ctl reconfigure
@ -250,14 +250,14 @@ fi
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX
#================================================= #=================================================
ynh_script_progression --message="Reloading nginx web server..." --weight=1 ynh_script_progression --message="Reloading NGINX web server..." --weight=1
ynh_systemd_action --action=reload --service_name=nginx ynh_systemd_action --action=reload --service_name=nginx
#================================================= #=================================================
# RESTART GITLAB # RESTART GITLAB
#================================================= #=================================================
ynh_script_progression --message="Restarting gitlab..." --weight=15 ynh_script_progression --message="Restarting GitLab..." --weight=15
ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path="/var/log/$app/puma/current" --line_match="Listening on tcp://127.0.0.1:$portPuma" --timeout=300 ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path="/var/log/$app/puma/current" --line_match="Listening on tcp://127.0.0.1:$portPuma" --timeout=300
@ -265,4 +265,4 @@ ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path=
# END OF SCRIPT # END OF SCRIPT
#================================================= #=================================================
ynh_script_progression --message="Installation of $app completed" --last ynh_script_progression --message="Installation of GitLab completed" --last

View file

@ -39,7 +39,7 @@ fi
#================================================= #=================================================
# STOP GITLAB # STOP GITLAB
#================================================= #=================================================
ynh_script_progression --message="Stopping gitlab" --weight=8 ynh_script_progression --message="Stopping GitLab" --weight=8
# I use gitlab-ctl and not ynh_systemd_action or systemctl to stop the service to avoid this error: https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/doc/common_installation_problems/README.md#reconfigure-freezes-at-ruby_blocksupervise_redis_sleep-action-run during the reinstall of the app # I use gitlab-ctl and not ynh_systemd_action or systemctl to stop the service to avoid this error: https://gitlab.com/gitlab-org/omnibus-gitlab/blob/master/doc/common_installation_problems/README.md#reconfigure-freezes-at-ruby_blocksupervise_redis_sleep-action-run during the reinstall of the app
gitlab-ctl stop gitlab-ctl stop
@ -47,7 +47,7 @@ gitlab-ctl stop
#================================================= #=================================================
# REMOVE GITLAB # REMOVE GITLAB
#================================================= #=================================================
ynh_script_progression --message="Removing Gitlab" --weight=4 ynh_script_progression --message="Removing GitLab" --weight=4
dpkg --remove gitlab-ce dpkg --remove gitlab-ce
@ -71,9 +71,9 @@ ynh_secure_remove --file="$config_path"
#================================================= #=================================================
# REMOVE NGINX CONFIGURATION # REMOVE NGINX CONFIGURATION
#================================================= #=================================================
ynh_script_progression --message="Removing nginx web server configuration" --weight=1 ynh_script_progression --message="Removing NGINX web server configuration" --weight=1
# Remove the dedicated nginx config # Remove the dedicated NGINX config
ynh_remove_nginx_config ynh_remove_nginx_config
#================================================= #=================================================
@ -110,4 +110,4 @@ ynh_del_swap
# END OF SCRIPT # END OF SCRIPT
#================================================= #=================================================
ynh_script_progression --message="Removal of $app completed" --last ynh_script_progression --message="Removal of GitLab completed" --last

View file

@ -87,7 +87,7 @@ ynh_add_swap --size=$swap_needed
#================================================= #=================================================
# RESTORE CONF FILES # RESTORE CONF FILES
#================================================= #=================================================
ynh_script_progression --message="Restoring configuration files of Gitlab..." --weight=1 ynh_script_progression --message="Restoring configuration files of GitLab..." --weight=1
ynh_restore_file --origin_path="$config_path/gitlab-secrets.json" ynh_restore_file --origin_path="$config_path/gitlab-secrets.json"
ynh_restore_file --origin_path="$config_path/gitlab.rb" ynh_restore_file --origin_path="$config_path/gitlab.rb"
@ -96,7 +96,7 @@ ynh_restore_file --origin_path="$config_path/gitlab-persistent.rb"
#================================================= #=================================================
# RESTORE THE APP MAIN DIR # RESTORE THE APP MAIN DIR
#================================================= #=================================================
ynh_script_progression --message="Reinstalling gitlab..." --weight=200 ynh_script_progression --message="Reinstalling GitLab..." --weight=50
source ../settings/scripts/upgrade.d/upgrade.last.sh source ../settings/scripts/upgrade.d/upgrade.last.sh
mkdir -p ../conf/ mkdir -p ../conf/
@ -121,7 +121,7 @@ fi
#================================================= #=================================================
# RESTORE GITLAB DATABASE # RESTORE GITLAB DATABASE
#================================================= #=================================================
ynh_script_progression --message="Restoring Gitlab..." --weight=55 ynh_script_progression --message="Restoring GitLab..." --weight=35
ynh_restore_file --origin_path="/var/opt/$app/backups/last_gitlab_backup.tar" ynh_restore_file --origin_path="/var/opt/$app/backups/last_gitlab_backup.tar"
@ -150,7 +150,7 @@ yunohost service add "gitlab-runsvdir" --log "/var/log/$app/gitlab-rails/applica
#================================================= #=================================================
# WAITING GITLAB # WAITING GITLAB
#================================================= #=================================================
ynh_script_progression --message="Waiting for gitlab..." --weight=14 ynh_script_progression --message="Waiting for GitLab..." --weight=14
ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path="/var/log/$app/puma/current" --line_match="Listening on tcp://127.0.0.1:$portPuma" --timeout=300 ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path="/var/log/$app/puma/current" --line_match="Listening on tcp://127.0.0.1:$portPuma" --timeout=300
@ -163,7 +163,7 @@ gitlab-rake gitlab:check SANITIZE=true
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX
#================================================= #=================================================
ynh_script_progression --message="Reloading nginx web server..." --weight=1 ynh_script_progression --message="Reloading NGINX web server..." --weight=1
ynh_systemd_action --action=reload --service_name=nginx ynh_systemd_action --action=reload --service_name=nginx
@ -171,4 +171,4 @@ ynh_systemd_action --action=reload --service_name=nginx
# END OF SCRIPT # END OF SCRIPT
#================================================= #=================================================
ynh_script_progression --message="Restoration completed for $app" --last ynh_script_progression --message="Restoration completed for GitLab" --last

View file

@ -172,13 +172,6 @@ ynh_clean_setup () {
# Exit if an error occurs during the execution of the script # Exit if an error occurs during the execution of the script
ynh_abort_if_errors ynh_abort_if_errors
#=================================================
# CHECK THE PATH
#=================================================
# Normalize the URL path syntax
path_url=$(ynh_normalize_url_path $path_url)
#================================================= #=================================================
# STANDARD UPGRADE STEPS # STANDARD UPGRADE STEPS
#================================================= #=================================================
@ -216,7 +209,7 @@ ynh_add_swap --size=$swap_needed
if [ "$upgrade_type" == "UPGRADE_APP" ] if [ "$upgrade_type" == "UPGRADE_APP" ]
then then
ynh_script_progression --message="Setting up source files..." --weight=200 ynh_script_progression --message="Setting up source files..." --weight=50
# To avoid the automatic backup, already performed by YunoHost: https://docs.gitlab.com/omnibus/update/#updating-methods # To avoid the automatic backup, already performed by YunoHost: https://docs.gitlab.com/omnibus/update/#updating-methods
touch $config_path/skip-auto-backup touch $config_path/skip-auto-backup
@ -238,7 +231,7 @@ then
fi fi
} }
# To update gitlab from major version A to B, we have to go to the last minor version # To update GitLab from major version A to B, we have to go to the last minor version
# of the major version A and then go to the first minor version of the major version B # of the major version A and then go to the first minor version of the major version B
# to finally go to the current minor version of the major version B # to finally go to the current minor version of the major version B
# A.last -> B.first -> B.last # A.last -> B.first -> B.last
@ -291,7 +284,7 @@ fi
#================================================= #=================================================
# RECONFIGURE GITLAB # RECONFIGURE GITLAB
#================================================= #=================================================
ynh_script_progression --message="Reconfigure gitlab..." --weight=13 ynh_script_progression --message="Reconfigure GitLab..." --weight=13
ynh_backup_if_checksum_is_different --file="$config_path/gitlab.rb" ynh_backup_if_checksum_is_different --file="$config_path/gitlab.rb"
@ -324,7 +317,7 @@ gitlab-ctl reconfigure
# Overwrite the nginx configuration only if it's allowed # Overwrite the nginx configuration only if it's allowed
if [ $overwrite_nginx -eq 1 ] if [ $overwrite_nginx -eq 1 ]
then then
ynh_script_progression --message="Configuring nginx web server..." --weight=2 ynh_script_progression --message="Configuring NGINX web server..." --weight=2
# Create a dedicated nginx config # Create a dedicated nginx config
ynh_add_nginx_config client_max_body_size ynh_add_nginx_config client_max_body_size
fi fi
@ -353,7 +346,7 @@ fi
if [ "$upgrade_type" == "UPGRADE_APP" ] if [ "$upgrade_type" == "UPGRADE_APP" ]
then then
ynh_script_progression --message="Restarting gitlab..." --weight=15 ynh_script_progression --message="Restarting GitLab..." --weight=15
ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path="/var/log/$app/puma/current" --line_match="Listening on tcp://127.0.0.1:$portPuma" --timeout=300 ynh_systemd_action --action=restart --service_name="gitlab-runsvdir" --log_path="/var/log/$app/puma/current" --line_match="Listening on tcp://127.0.0.1:$portPuma" --timeout=300
fi fi
@ -361,7 +354,7 @@ fi
#================================================= #=================================================
# RELOAD NGINX # RELOAD NGINX
#================================================= #=================================================
ynh_script_progression --message="Reloading nginx web server..." --weight=1 ynh_script_progression --message="Reloading NGINX web server..." --weight=1
ynh_systemd_action --action=reload --service_name=nginx ynh_systemd_action --action=reload --service_name=nginx
@ -369,4 +362,4 @@ ynh_systemd_action --action=reload --service_name=nginx
# END OF SCRIPT # END OF SCRIPT
#================================================= #=================================================
ynh_script_progression --message="Upgrade of $app completed" --last ynh_script_progression --message="Upgrade of GitLab completed" --last

View file

@ -1,13 +1,13 @@
#!/bin/bash #!/bin/bash
gitlab_version="13.6.3" gitlab_version="13.7.0"
# sha256sum found here: https://packages.gitlab.com/gitlab # sha256sum found here: https://packages.gitlab.com/gitlab
gitlab_debian_version="buster" gitlab_debian_version="buster"
gitlab_x86_64_buster_source_sha256="1a8092038da1541e8306d0d17e2d744cee8919908f41e37d80f48ad6273cde5c" gitlab_x86_64_buster_source_sha256="ae199a8dda08c7bbd7e743fc05e3eaee0ca0b0946deddc19c4bcfa8dc8852ad1"
gitlab_arm_buster_source_sha256="3d18ce34311a8e19efbc8aec5bb9c58fa7c41558ad0b476685c18e828bf53d6c" gitlab_arm_buster_source_sha256="fc423975c33eb3e43a5fbbcceb4f35afa1f9241108e3ba0233dd384a349b0d89"
architecture=$(ynh_app_setting_get --app="$app" --key=architecture) architecture=$(ynh_app_setting_get --app="$app" --key=architecture)