ci: remove unnecessary files and align with what mautrix-slack has

Signed-off-by: Sumner Evans <sumner.evans@automattic.com>
This commit is contained in:
Sumner Evans
2024-07-15 11:02:40 -06:00
parent 5eaec4d0e0
commit 62f77686c4
4 changed files with 8 additions and 42 deletions
+5 -4
View File
@@ -4,7 +4,8 @@ if [[ -z "$GID" ]]; then
GID="$UID"
fi
# Define functions.
BINARY_NAME=/usr/bin/mautrix-telegram
function fixperms {
chown -R $UID:$GID /data
@@ -15,7 +16,7 @@ function fixperms {
}
if [[ ! -f /data/config.yaml ]]; then
cp /opt/mautrix-telegram/example-config.yaml /data/config.yaml
$BINARY_NAME -c /data/config.yaml -e
echo "Didn't find a config file."
echo "Copied default config file to /data/config.yaml"
echo "Modify that config file to your liking."
@@ -24,7 +25,7 @@ if [[ ! -f /data/config.yaml ]]; then
fi
if [[ ! -f /data/registration.yaml ]]; then
/usr/bin/mautrix-telegram -g -c /data/config.yaml -r /data/registration.yaml || exit $?
$BINARY_NAME -g -c /data/config.yaml -r /data/registration.yaml
echo "Didn't find a registration file."
echo "Generated one for you."
echo "See https://docs.mau.fi/bridges/general/registering-appservices.html on how to use it."
@@ -33,4 +34,4 @@ fi
cd /data
fixperms
exec su-exec $UID:$GID /usr/bin/mautrix-telegram
exec su-exec $UID:$GID $BINARY_NAME