From 813b33769e0eec1d5ff846f22ffd4fe42fa5d7a5 Mon Sep 17 00:00:00 2001 From: Rodrigo Nardi Date: Tue, 21 Nov 2023 16:43:28 -0300 Subject: [PATCH 1/2] Services Fixing user and description --- service/prod/slack_cibot.service | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/service/prod/slack_cibot.service b/service/prod/slack_cibot.service index f771eb2..b5ec28e 100644 --- a/service/prod/slack_cibot.service +++ b/service/prod/slack_cibot.service @@ -1,9 +1,9 @@ [Unit] -Description="CI Slack Bot DEVEL" +Description="CI Slack Bot PRODUCTION" After=network.target [Service] -User=slack_cibot_devel +User=slack_cibot WorkingDirectory=/home/slack_cibot/slack_github_bot ExecStart=/home/slack_cibot/slack_github_bot/service/prod/server.sh Restart=always From 314cd404e1352a27d2a51b4c2272d12c304e2454 Mon Sep 17 00:00:00 2001 From: Rodrigo Nardi Date: Tue, 12 Dec 2023 11:18:28 -0300 Subject: [PATCH 2/2] Client Bot Setting unfurl_links and unfurl_media to false --- lib/slack/client.rb | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/lib/slack/client.rb b/lib/slack/client.rb index 2b25bd0..da40082 100644 --- a/lib/slack/client.rb +++ b/lib/slack/client.rb @@ -24,7 +24,11 @@ def initialize end def chat(message, channel: fetch_channel) - @client.chat_postMessage(channel: channel, text: message, username: fetch_bot_name) + @client.chat_postMessage(channel: channel, + text: message, + username: fetch_bot_name, + unfurl_links: false, + unfurl_media: false) rescue Slack::Web::Api::Errors::TooManyRequestsError sleep 60 retry