feat(channels): add Mattermost integration for sovereign communication
This commit is contained in:
parent
0aa35eb669
commit
7e3f5ff497
7 changed files with 408 additions and 3 deletions
|
|
@ -6,6 +6,7 @@ pub mod imessage;
|
|||
pub mod irc;
|
||||
pub mod lark;
|
||||
pub mod matrix;
|
||||
pub mod mattermost;
|
||||
pub mod qq;
|
||||
pub mod signal;
|
||||
pub mod slack;
|
||||
|
|
@ -21,6 +22,7 @@ pub use imessage::IMessageChannel;
|
|||
pub use irc::IrcChannel;
|
||||
pub use lark::LarkChannel;
|
||||
pub use matrix::MatrixChannel;
|
||||
pub use mattermost::MattermostChannel;
|
||||
pub use qq::QQChannel;
|
||||
pub use signal::SignalChannel;
|
||||
pub use slack::SlackChannel;
|
||||
|
|
@ -1118,6 +1120,15 @@ pub async fn start_channels(config: Config) -> Result<()> {
|
|||
)));
|
||||
}
|
||||
|
||||
if let Some(ref mm) = config.channels_config.mattermost {
|
||||
channels.push(Arc::new(MattermostChannel::new(
|
||||
mm.url.clone(),
|
||||
mm.bot_token.clone(),
|
||||
mm.channel_id.clone(),
|
||||
mm.allowed_users.clone(),
|
||||
)));
|
||||
}
|
||||
|
||||
if let Some(ref im) = config.channels_config.imessage {
|
||||
channels.push(Arc::new(IMessageChannel::new(im.allowed_contacts.clone())));
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue