浏览代码

Merge branch 'stretch' of https://github.com/bashrc/freedombone

Bob Mottram 6 年前
父节点
当前提交
efd32577e5
共有 1 个文件被更改,包括 15 次插入3 次删除
  1. 15
    3
      src/freedombone-app-matrix

+ 15
- 3
src/freedombone-app-matrix 查看文件

48
 MATRIX_FEDERATION_ONION_PORT=8111
48
 MATRIX_FEDERATION_ONION_PORT=8111
49
 MATRIX_ONION_PORT=8109
49
 MATRIX_ONION_PORT=8109
50
 MATRIX_REPO="https://github.com/matrix-org/synapse"
50
 MATRIX_REPO="https://github.com/matrix-org/synapse"
51
-MATRIX_COMMIT='ab5e888927e6a38190a65e10af7acf67873124e3'
51
+MATRIX_COMMIT='9e8ab0a4f44a3ec9e4b049f5571c14e333e8f0fa'
52
 REPORT_STATS="no"
52
 REPORT_STATS="no"
53
 MATRIX_SECRET=
53
 MATRIX_SECRET=
54
 MATRIX_EXPIRE_MONTHS=1
54
 MATRIX_EXPIRE_MONTHS=1
418
     function_check set_repo_commit
418
     function_check set_repo_commit
419
     set_repo_commit /etc/matrix "matrix commit" "$MATRIX_COMMIT" $MATRIX_REPO
419
     set_repo_commit /etc/matrix "matrix commit" "$MATRIX_COMMIT" $MATRIX_REPO
420
     cd /etc/matrix || exit 62476724
420
     cd /etc/matrix || exit 62476724
421
+    if [ ! -d /etc/matrix/tmp ]; then
422
+        mkdir /etc/matrix/tmp
423
+    fi
424
+    export TMPDIR=/etc/matrix/tmp
425
+
421
     pip install --upgrade --process-dependency-links .
426
     pip install --upgrade --process-dependency-links .
422
     pip install --upgrade --force "pynacl>=1.2.1"
427
     pip install --upgrade --force "pynacl>=1.2.1"
423
 
428
 
426
     chown -R matrix:matrix /etc/matrix
431
     chown -R matrix:matrix /etc/matrix
427
     chown -R matrix:matrix $MATRIX_DATA_DIR
432
     chown -R matrix:matrix $MATRIX_DATA_DIR
428
 
433
 
429
-    pip install --upgrade --force "pynacl==0.3.0"
434
+    pip install --upgrade --force "pynacl>=1.2.1"
435
+    pip install --upgrade --force "canonicaljson>=1.1.3"
430
     pip install --upgrade --force "phonenumbers>=8.2.0"
436
     pip install --upgrade --force "phonenumbers>=8.2.0"
431
 
437
 
432
     if [ -f /etc/ssl/certs/${MATRIX_DOMAIN_NAME}.dhparam ]; then
438
     if [ -f /etc/ssl/certs/${MATRIX_DOMAIN_NAME}.dhparam ]; then
434
     fi
440
     fi
435
     systemctl start turn
441
     systemctl start turn
436
     systemctl start matrix
442
     systemctl start matrix
443
+
444
+    export TMPDIR=/tmp
445
+    if [ -d /etc/matrix/tmp ]; then
446
+        rm -rf /etc/matrix/tmp/*
447
+    fi
437
 }
448
 }
438
 
449
 
439
 function backup_local_matrix {
450
 function backup_local_matrix {
794
     # wait for nginx to start otherwise user add fails later
805
     # wait for nginx to start otherwise user add fails later
795
     sleep 5
806
     sleep 5
796
 
807
 
797
-    pip install --upgrade --force "pynacl==0.3.0"
808
+    pip install --upgrade --force "pynacl>=1.2.1"
809
+    pip install --upgrade --force "canonicaljson>=1.1.3"
798
 
810
 
799
     if [[ $(add_user_matrix "${MY_USERNAME}" "${MATRIX_PASSWORD}" | tail -n 1) != "0" ]]; then
811
     if [[ $(add_user_matrix "${MY_USERNAME}" "${MATRIX_PASSWORD}" | tail -n 1) != "0" ]]; then
800
         echo $'Failed to add matrix admin user';
812
         echo $'Failed to add matrix admin user';