2021-01-24 08:41:11 +02:00
|
|
|
#jinja2: lstrip_blocks: "True"
|
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
if [ $# -ne 2 ]; then
|
2022-08-24 05:59:08 +02:00
|
|
|
echo "Usage: "$0" <username> <password> <admin access: 0 or 1>"
|
2021-01-24 08:41:11 +02:00
|
|
|
exit 1
|
|
|
|
fi
|
|
|
|
|
|
|
|
user=$1
|
|
|
|
password=$2
|
2022-08-23 18:12:09 +02:00
|
|
|
admin=$3
|
2021-01-24 08:41:11 +02:00
|
|
|
|
2022-08-23 18:12:09 +02:00
|
|
|
if [ "$admin" -eq "1" ]; then
|
|
|
|
docker exec matrix-dendrite create-account -config /data/dendrite.yaml -username "$user" -password "$password" -admin -url http://localhost:{{ matrix_dendrite_http_bind_port }}
|
|
|
|
else
|
|
|
|
docker exec matrix-dendrite create-account -config /data/dendrite.yaml -username "$user" -password "$password" -url http://localhost:{{ matrix_dendrite_http_bind_port }}
|
|
|
|
fi
|