Update start.sh: fix path for homeserver.yaml and upgrade.json; enhance security by clearing registration_shared_secret
This commit is contained in:
4
start.sh
4
start.sh
@@ -118,10 +118,10 @@ register_admin_user() {
|
|||||||
echo "Admin user created successfully!"
|
echo "Admin user created successfully!"
|
||||||
|
|
||||||
# renmove registration_shared_secret from homeserver.yaml for security
|
# renmove registration_shared_secret from homeserver.yaml for security
|
||||||
yq eval '.registration_shared_secret = ""' /data/homeserver.yaml > /data/homeserver.yaml.tmp && mv /data/homeserver.yaml.tmp /data/homeserver.yaml
|
yq eval '.registration_shared_secret = ""' /data/homeserver.yaml > /tmp/homeserver.yaml.tmp && mv /tmp/homeserver.yaml.tmp /data/homeserver.yaml
|
||||||
|
|
||||||
# trigger a restart of synapse to reload config
|
# trigger a restart of synapse to reload config
|
||||||
echo '{"NAME":"service-matrix.containers.matrixserver-app"}' | jq -r > /var/tmp/input/upgrade.json
|
echo '{"NAME":"service-matrix.containers.matrixserver-app"}' | jq -r > /var/tmp/shared/input/upgrade.json
|
||||||
echo "Matrix server app restart requested"
|
echo "Matrix server app restart requested"
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
|
Reference in New Issue
Block a user