mirror of
https://github.com/YunoHost-Apps/synapse_ynh.git
synced 2024-09-03 20:26:38 +02:00
Use prebuilt source for ARM
This commit is contained in:
parent
1b5d4c4764
commit
c6a8398ba1
4 changed files with 35 additions and 14 deletions
|
@ -14,7 +14,8 @@ If you don't have a dh.pem file in `/etc/yunohost/certs/YOUR DOMAIN/dh.pem` you
|
|||
You could built it by this cmd : `sudo openssl dhparam -out /etc/yunohost/certs/YOUR DOMAIN/dh.pem 2048 > /dev/null`
|
||||
After that you can install it without problem.
|
||||
|
||||
The install use the python virtualenvironement. Everything is built on the install and some package a compiled so it could take a long time if the processor is slow.
|
||||
The package use a prebuild python virtualenvironnement. The binary are taken from this repos : https://github.com/Josue-T/synapse_python_build
|
||||
The script to build the binary is also available.
|
||||
|
||||
### Package update package
|
||||
|
||||
|
|
12
conf/armv7.src
Normal file
12
conf/armv7.src
Normal file
|
@ -0,0 +1,12 @@
|
|||
|
||||
SOURCE_URL=https://github.com/Josue-T/synapse_python_build/releases/download/matrix-synapse_0.24.1-bin1_armv7l.tar.gz
|
||||
SOURCE_SUM=f1a4941b4feba49111eaf5dc85cff986ec63a2628eaea4a6d5bfcfe3162d0943
|
||||
# (Optional) Program to check the integrity (sha256sum, md5sum...)
|
||||
# default: sha256
|
||||
SOURCE_SUM_PRG=sha256sum
|
||||
# (Optional) Archive format
|
||||
# default: tar.gz
|
||||
SOURCE_FORMAT=tar.gz
|
||||
# (Optional) Put false if sources are directly in the archive root
|
||||
# default: true
|
||||
SOURCE_IN_SUBDIR=true
|
|
@ -5,10 +5,10 @@ app=$YNH_APP_INSTANCE_NAME
|
|||
synapse_user="matrix-synapse"
|
||||
synapse_db_name="matrix_synapse"
|
||||
synapse_db_user="matrix_synapse"
|
||||
synapse_version="0.22.0"
|
||||
synapse_version="0.24.1"
|
||||
|
||||
install_dependances() {
|
||||
ynh_install_app_dependencies coturn build-essential python2.7-dev libffi-dev python-pip python-setuptools sqlite3 libssl-dev python-virtualenv libjpeg-dev libpq-dev postgresql
|
||||
ynh_install_app_dependencies coturn build-essential python2.7-dev libffi-dev python-pip python-setuptools sqlite3 libssl-dev python-virtualenv libxml2-dev libxslt1-dev python-lxml libjpeg-dev libpq-dev postgresql
|
||||
pip install --upgrade pip
|
||||
pip install --upgrade virtualenv
|
||||
}
|
||||
|
@ -22,16 +22,24 @@ setup_dir() {
|
|||
}
|
||||
|
||||
install_source() {
|
||||
# Install synapse in virtualenv
|
||||
virtualenv -p python2.7 $final_path
|
||||
PS1=""
|
||||
cp ../conf/virtualenv_activate $final_path/bin/activate
|
||||
source $final_path/bin/activate
|
||||
pip install --upgrade pip
|
||||
pip install --upgrade cffi ndg-httpsclient setuptools
|
||||
pip install --upgrade https://github.com/matrix-org/synapse/tarball/master
|
||||
pip install --upgrade psycopg2 lxml
|
||||
deactivate
|
||||
|
||||
if [ -n "$(uname -m | grep arm)" ]
|
||||
then
|
||||
ynh_setup_source $final_path/ "armv7"
|
||||
else
|
||||
# Install virtualenv if it don't exist
|
||||
test -e $final_path/bin || virtualenv -p python2.7 $final_path
|
||||
|
||||
# Install synapse in virtualenv
|
||||
PS1=""
|
||||
cp ../conf/virtualenv_activate $final_path/bin/activate
|
||||
source $final_path/bin/activate
|
||||
pip install --upgrade pip
|
||||
pip install --upgrade setuptools
|
||||
pip install --upgrade cffi ndg-httpsclient psycopg2 lxml
|
||||
pip install --upgrade https://github.com/matrix-org/synapse/tarball/master
|
||||
deactivate
|
||||
fi
|
||||
|
||||
# Set permission
|
||||
chown $synapse_user:root -R $final_path
|
||||
|
|
|
@ -65,7 +65,7 @@ then
|
|||
install_dependances
|
||||
|
||||
# Create directory Install synapse in virtualenv
|
||||
setup_dir || true # If the dir aready exist, but to be sure that all dir exist.
|
||||
setup_dir || true # If the dir aready exist the command could fail
|
||||
install_source
|
||||
|
||||
# Open access to server without a button the home
|
||||
|
|
Loading…
Reference in a new issue