Code Monkey home page Code Monkey logo

steam-workshop-monitor's Introduction

Steam-Workshop-Monitor

Discord bot to notify you when your server mods get updated on the Steam workshop.

How it works

Upon joining it creates a channel and a role where it will send notifications, once a mod get's updated which you added using the /add command. This is achived by quering the public Steam API and comparing the update times with those stored in the database.

Commands

Integrated with Discord Slash commands!

image

Example

image image

Deployment

Requirements

  • Redis DB (Redis lab offers free hosting)
  • MySQL DB (Import DB from db.sql)
  • Discord bot (Needs scope applications.commands and bot-administrator)
  • Docker host

Docker Compose
Some things such as status, cleanup, top.gg task are hardcoded so require enabling in code and building your own image!

version: "3.1"
services:
  workshopmain:
    image: ghcr.io/urekd/steam-workshop-monitor:main	
    container_name: workshopmonitor
    environment:
      - RHOST=cloud.redislabs.com #Redis host
      - RPASS=testpassword #Redis pass
      - RPORT=50421 #Redis port
      - RUSER=default #Redis user
      - RINDEX=0 #Redis db index
      - TZ=Europe/Berlin #Your timezone
      - TOKEN=NzUyMjEzMDM3MDc5MDY4ODMy.X1UW-w.tcVSMWKbIU9smbSJa7EDAteqALU #Bot token
      - DBHOST=192.168.0.2 #MySQL host
      - DBUSER=workshopbot #MySQL User
      - DBPASS=pass123
      - DB=workshop
      - ccount=6 #Command times per CDTIME
      - cdtime=30 #Seconds of cooldown
      - ttltime=3600 #Redis key time to live
      - ctime=300 #Check interval in seconds
      - fdelay=120 #Run delay on monitor fail (ex. API is down)
      - chdebug=1234 (Channel where to send logs/debug to)
      - mincount=1 #Minimum count for mods Used in cleanup
    restart: unless-stopped

Personal note

As of release of 1.0 I have stopped development of the bot as my verification was rejected: "I want to confirm that we're denying your verification request due to some concerns regarding your bot’s operation...". I have left comments in the code to help if anyone wishes to continue with it's development, I sadly didn't get to refactor nor implement all the things I had planned. The bot is fully functioning, the only bug I found was that ever since I moved it out of Oracle's cloud Redis likes to trow a 'connection reset by peer' every few hours. I also included a Drone pipeline I used with Gitea to automate deployment using Portainer, which makes it super simple to redeploy while developing.

The hosted instance of the bot will still be avaliable until further notice, but no guarantee of it's operation is given! Invite the bot to your guild. Official Discord Server. If you want to monitor 25 or less items you can use Steam Watch Bot.

steam-workshop-monitor's People

Contributors

urekd avatar deepsource-autofix[bot] avatar dependabot[bot] avatar deepsourcebot avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.