Update to seafile v5.0.3

Former-commit-id: c4d7ae40fc
This commit is contained in:
mbugeia 2015-12-26 13:44:01 +01:00
parent 48832d86e7
commit e531dfdae3
8 changed files with 34 additions and 23 deletions

11
conf/upgrade_5.0.3.exp Normal file
View file

@ -0,0 +1,11 @@
#!/usr/bin/expect
set timeout 5
set mysql_password [lindex $argv 0]
spawn /var/www/seafile/seafile-server-5.0.3/upgrade/upgrade_4.4_5.0.sh
expect "to contiune"
send "\r";
interact

View file

@ -12,7 +12,7 @@ is_public=$6
architecture=$7 architecture=$7
final_path=/var/www/$app final_path=/var/www/$app
seafile_data=/home/yunohost.app/seafile-data seafile_data=/home/yunohost.app/seafile-data
seafile_version=4.4.3 seafile_version=5.0.3
# Retrieve admin email # Retrieve admin email
admin_email=$(sudo yunohost user info $admin | grep mail: | sed "s/mail: //g") admin_email=$(sudo yunohost user info $admin | grep mail: | sed "s/mail: //g")
@ -78,29 +78,29 @@ sudo chmod +x $final_path/seafile-server-$seafile_version/setup-seafile-mysql.sh
sudo ../conf/install.exp $server_name $domain $seafile_data $fileserver_port $db_pwd sudo ../conf/install.exp $server_name $domain $seafile_data $fileserver_port $db_pwd
# Update seafile config # Update seafile config
sudo sed -i "s@http://@https://@g" $final_path/ccnet/ccnet.conf sudo sed -i "s@http://@https://@g" $final_path/conf/ccnet.conf
sudo sed -i "s@:8000@$path@g" $final_path/ccnet/ccnet.conf sudo sed -i "s@:8000@$path@g" $final_path/conf/ccnet.conf
echo 'FILE_SERVER_ROOT = "https://'$domain'/seafhttp"' | sudo tee -a $final_path/seahub_settings.py echo 'FILE_SERVER_ROOT = "https://'$domain'/seafhttp"' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'SITE_ROOT = "'$path'/"' | sudo tee -a $final_path/seahub_settings.py echo 'SITE_ROOT = "'$path'/"' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'SERVE_STATIC = False' | sudo tee -a $final_path/seahub_settings.py echo 'SERVE_STATIC = False' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'MEDIA_URL = "'$path'/media/"' | sudo tee -a $final_path/seahub_settings.py echo 'MEDIA_URL = "'$path'/media/"' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'COMPRESS_URL = MEDIA_URL' | sudo tee -a $final_path/seahub_settings.py echo 'COMPRESS_URL = MEDIA_URL' | sudo tee -a $final_path/conf/seahub_settings.py
echo "STATIC_URL = MEDIA_URL + 'assets/'" | sudo tee -a $final_path/seahub_settings.py echo "STATIC_URL = MEDIA_URL + 'assets/'" | sudo tee -a $final_path/conf/seahub_settings.py
# Email configuration # Email configuration
echo 'EMAIL_USE_TLS = False' | sudo tee -a $final_path/seahub_settings.py echo 'EMAIL_USE_TLS = False' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'EMAIL_HOST = "localhost"' | sudo tee -a $final_path/seahub_settings.py echo 'EMAIL_HOST = "localhost"' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'EMAIL_HOST_USER = "seafile@'$domain'"' | sudo tee -a $final_path/seahub_settings.py echo 'EMAIL_HOST_USER = "seafile@'$domain'"' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'EMAIL_HOST_PASSWORD = ""' | sudo tee -a $final_path/seahub_settings.py echo 'EMAIL_HOST_PASSWORD = ""' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'EMAIL_PORT = "25"' | sudo tee -a $final_path/seahub_settings.py echo 'EMAIL_PORT = "25"' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'DEFAULT_FROM_EMAIL = "seafile@'$domain'"' | sudo tee -a $final_path/seahub_settings.py echo 'DEFAULT_FROM_EMAIL = "seafile@'$domain'"' | sudo tee -a $final_path/conf/seahub_settings.py
echo 'SERVER_EMAIL = "seafile@'$domain'"' | sudo tee -a $final_path/seahub_settings.py echo 'SERVER_EMAIL = "seafile@'$domain'"' | sudo tee -a $final_path/conf/seahub_settings.py
# LDAP configuration # LDAP configuration
echo '[LDAP]' | sudo tee -a $final_path/ccnet/ccnet.conf echo '[LDAP]' | sudo tee -a $final_path/conf/ccnet.conf
echo 'HOST = ldap://localhost:389' | sudo tee -a $final_path/ccnet/ccnet.conf echo 'HOST = ldap://localhost:389' | sudo tee -a $final_path/conf/ccnet.conf
echo 'BASE = ou=users,dc=yunohost,dc=org' | sudo tee -a $final_path/ccnet/ccnet.conf echo 'BASE = ou=users,dc=yunohost,dc=org' | sudo tee -a $final_path/conf/ccnet.conf
echo 'LOGIN_ATTR = mail' | sudo tee -a $final_path/ccnet/ccnet.conf echo 'LOGIN_ATTR = mail' | sudo tee -a $final_path/conf/ccnet.conf
# Add Seafile Server to startup # Add Seafile Server to startup
sudo cp ../conf/seafile-server /etc/init.d sudo cp ../conf/seafile-server /etc/init.d

View file

@ -1 +0,0 @@
6a24a05a0990ca9f47644914c363630a4b416c77

View file

@ -1 +0,0 @@
38803ad3a16da3bbc3a20b4b9fae20ec7709ce22

View file

@ -1 +0,0 @@
c2866ea4587005d380327ba095bf1a4ae790bceb

View file

@ -0,0 +1 @@
601f5fefe734566c4592b46ff22f4c9ab8bcea43

View file

@ -0,0 +1 @@
dc83ddf23814ca7dc5e0093ce4f3ad82ec310cbc

View file

@ -0,0 +1 @@
452bfdd255d6f1cc2e8c9ea5b26ea929090b2c51