Small Tutorial, How to Display Google Calendar in a Channel Description

Requirements:

  • VPS (virtual private server, Linux Preferred)
  • Apache Webserver with a website that is running
  • a Functional Teamspeak Server
  • Python 3

Needed:

Steps:
I am not going into full detail, if you read this i assume you followed the tutorials on the above websites !!

  1. Create a Google API Key https://console.developers.google.com For more info read the tutorial on this webpage: GitHub - OrcaCollective/google-calendar-helpers: Extract RSS feeds from the Google Calendar API

2.Download and extract/Deploy the Google Calendar Helpers Script, i would advice you to put it into your apache folder, since this is public accesable ( /var/www/html/Calendar)

  1. Configure config.py.example and change the name to config.py when you are done. (you only need to fill in the details of the Google stuff)

  2. test the script python gen_rss.py → if succesfull it will create a folder called output with yourfile.rss

  3. Install Sinusbot (follow the tutorial on Linux - SinusBot Documentation) & make your sinusbot admin or assign the right permissions for channel editting

  4. Download the rss reader script and place it in /opt/sinusbot/scripts

  5. Restart Sinusbot and log into the Sinusbot webinterface

  6. on the web interface open settings → scripts and look for RSSFeed

  7. set it to english, give it the timeinterval you want (i have 60 minutes)

  8. Configure your RSSFeed

  • Rssfeedlink → Fastest Web Hosting Services | Buy High Quality Hosting
  • feed to channel (specify your calendar channel here)
  • Maxfeed 0 (amount of items displayed)
  • Limit Characters 300
  • Feed Array output: [size=+2]%FeedTitle[/size]
    %Feedday %Feedmonth %Feedyear
    %FeedTime
  • The other settings can be left empty
  1. look in your teamspeak if the channel is updated, if not check your sinusbotlog

  2. Final Step: since the serverside is not automated yet, you need to create a cronjob, if you do not know what it is please search for it. Basicly it is a small script/task you create to make stuff automaticly happen

Open your Linux Terminal and do this:
sudo crontab -e
MAILTO=“”
SHELL=/bin/bash

0 * * * * cd /var/www/html/calendar && source venv/bin/activate && python gen_rss.py

Then save this, with these settings and if you do everything right you will have a calendar channel that updates every hour.

If you are unsure Reboot everything and see if it is working.

1 Like