diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..1babff8 --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule "communication/slack/bot"] + path = communication/slack/bot + url = https://github.com/ekmartin/slack-irc diff --git a/communication/slack/README.md b/communication/slack/README.md new file mode 100644 index 0000000..d062c2e --- /dev/null +++ b/communication/slack/README.md @@ -0,0 +1,14 @@ +# Slack sync to IRC +Bot that will do sync between slack and certain slack channnels + +# Prerequisites +nodejs (tested with 0.12) + +npm install -g slack-irc + +# Files +openfest-slack-to-irc-sync.json - config with sensitive information removed +We are using ssl to connect + +slack-irc@.service systemd templated unit so you can run multiple instances +Running multiple slack-irc instances has not been tested diff --git a/communication/slack/bot b/communication/slack/bot new file mode 160000 index 0000000..f005c1f --- /dev/null +++ b/communication/slack/bot @@ -0,0 +1 @@ +Subproject commit f005c1f4536fe47799bc2741ff09730e7fdea891 diff --git a/communication/slack/config/openfest-slack-to-irc-sync.json b/communication/slack/config/openfest-slack-to-irc-sync.json new file mode 100644 index 0000000..fd70dd4 --- /dev/null +++ b/communication/slack/config/openfest-slack-to-irc-sync.json @@ -0,0 +1,18 @@ +[{ + "nickname": "SlackSync", + "server": "marla.ludost.net", + "token": "CHANGE ME", + "channelMapping": { + "private": "private" + "#bulgaria-hall": "#openfest-bulgaria-hall", + "#chamber-hall": "#openfest-chamber-hall", + "#third-hall": "#openfest-third-hall" + }, + "ircOptions": { + "userName": "slacksync", + "realName": "Slack to IRC bidirectional Sync Bot", + "debug": true, + "secure": "true", + "port": 6697 + } +}] diff --git a/communication/slack/config/slack-irc@.service b/communication/slack/config/slack-irc@.service new file mode 100644 index 0000000..2f38fff --- /dev/null +++ b/communication/slack/config/slack-irc@.service @@ -0,0 +1,12 @@ +[Unit] +Description=Slack to IRC sync bot (%i) +After=network.target + +[Service] +User=nobody +Group=nogroup +PrivateTmp=yes +ExecStart=/usr/bin/slack-irc -c /etc/slack-irc/%i.json + +[Install] +WantedBy=multi-user.target