From 33bd60528be4eaf28ffd1065517ea41fde9ea62b Mon Sep 17 00:00:00 2001 From: Remi Reuvekamp Date: Fri, 8 Jun 2018 22:30:35 +0200 Subject: Add config option MediaDownloadPath (#443) * Add config option MediaUploadPath MediaDownloadPath can be used instead of MediaServerUpload, for when your webserver is on the same system as matterbridge and matterbridge has write access to the serve dir. * Limit length of hash in MediaServer urls to 8chars Full SHA256 is unnecessary for uniqueness. Also; if a file has the same first 8 charachters of the SHA256 hash, it's still not a problem, as long as the filename is not the same. --- matterbridge.toml.sample | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'matterbridge.toml.sample') diff --git a/matterbridge.toml.sample b/matterbridge.toml.sample index 6f81baf6..1bc4f3b4 100644 --- a/matterbridge.toml.sample +++ b/matterbridge.toml.sample @@ -1306,10 +1306,13 @@ RemoteNickFormat="[{PROTOCOL}] <{NICK}> " StripNick=false -#MediaServerUpload and MediaServerDownload are used for uploading images/files/video to -#a remote "mediaserver" (a webserver like caddy for example). -#When configured images/files uploaded on bridges like mattermost,slack, telegram will be downloaded -#and uploaded again to MediaServerUpload URL +#MediaServerUpload (or MediaDownloadPath) and MediaServerDownload are used for uploading +#images/files/video to a remote "mediaserver" (a webserver like caddy for example). +#When configured images/files uploaded on bridges like mattermost, slack, telegram will be +#downloaded and uploaded again to MediaServerUpload URL +#MediaDownloadPath is the filesystem path where the media file will be placed, instead of uploaded, +#for if Matterbridge has write access to the directory your webserver is serving. +#It is an alternative to MediaServerUpload. #The MediaServerDownload will be used so that bridges without native uploading support: #gitter, irc and xmpp will be shown links to the files on MediaServerDownload # @@ -1317,6 +1320,8 @@ StripNick=false #OPTIONAL (default empty) MediaServerUpload="https://user:pass@yourserver.com/upload" #OPTIONAL (default empty) +MediaDownloadPath="/srv/http/yourserver.com/public/download" +#OPTIONAL (default empty) MediaServerDownload="https://youserver.com/download" #MediaDownloadSize is the maximum size of attachments, videos, images -- cgit v1.2.3