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

Fix resinstall the application after a removing

This commit is contained in:
Kayou 2019-02-01 23:24:57 +01:00
parent d04d84d7ab
commit 7c52dabae4
No known key found for this signature in database
GPG key ID: 823A2CBE071D3126
3 changed files with 8 additions and 1 deletions

View file

@ -2,7 +2,7 @@
"name": "Gitlab", "name": "Gitlab",
"id": "gitlab", "id": "gitlab",
"packaging_format": 1, "packaging_format": 1,
"version": "11.7.3~ynh1", "version": "11.7.3~ynh2",
"description": { "description": {
"en": "Gitlab for Yunohost.", "en": "Gitlab for Yunohost.",
"fr": "Gitlab pour YunoHost." "fr": "Gitlab pour YunoHost."

View file

@ -144,6 +144,7 @@ waiting_to_start() {
line_match_new="adopted new unicorn master" line_match_new="adopted new unicorn master"
line_match_existing="adopted existing unicorn master" line_match_existing="adopted existing unicorn master"
line_match_error="master failed to start"
clean_check_starting() { clean_check_starting() {
# Stop the execution of tail # Stop the execution of tail
@ -157,6 +158,10 @@ waiting_to_start() {
# get the PID of the tail command # get the PID of the tail command
local pid_tail=$! local pid_tail=$!
if grep --quiet "${line_match_error}" $templog; then # error, so restart gitlab
gitlab-ctl restart
fi
for i in $(seq 1 3600); do for i in $(seq 1 3600); do
if grep --quiet "${line_match_new}" $templog || grep --quiet "${line_match_existing}" $templog; then if grep --quiet "${line_match_new}" $templog || grep --quiet "${line_match_existing}" $templog; then
echo "Gitlab has correctly started." >&2 echo "Gitlab has correctly started." >&2

View file

@ -30,6 +30,8 @@ portUnicorn=$(ynh_app_setting_get "$app" unicorn_port)
ynh_print_info "Removing Gitlab..." ynh_print_info "Removing Gitlab..."
gitlab-ctl stop
# Remove gitlab # Remove gitlab
dpkg --remove gitlab-ce dpkg --remove gitlab-ce