Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.
/ Newsblast Public archive

A Discord bot that provides RSS updates.

License

Notifications You must be signed in to change notification settings

jonathanpotts/Newsblast

Repository files navigation

Newsblast

A Discord bot that provides RSS updates.

Uses .NET Core 2.1, Entity Framework Core 2.1, Discord.Net, and Html Agility Pack.

Configuration

The following settings must be configured before running Newsblast.

Newsblast.Server

The configuration for Newsblast.Server is stored in Newsblast.Server.json. If the file does not exist, run Newsblast.Server and the file will be created if the file permissions are set correctly.

  • DiscordBotToken: The bot token for your Discord application. It can be found in the Discord Developer Portal.
  • SqlServerConnectionString: The connection string for the SQL Server database or Azure SQL Database used for storing data for the bot.

Newsblast.Web

The configuration for Newsblast.Web can be stored in several different locations. Refer to the ASP.NET Core 2.1 documentation for more information.

Connection Strings

  • SqlServerConnectionString: The connection string for the SQL Server database or Azure SQL Database used for storing data for the bot.

Application Settings

  • DiscordClientId: The client ID for your Discord application. It can be found in the Discord Developer Portal.
  • DiscordClientSecret: The client secret for your Discord application. It can be found in the Discord Developer Portal.
  • DiscordBotToken: The bot token for your Discord application. It can be found in the Discord Developer Portal.
  • AdministratorIds: A comma-delimited list of the Discord User IDs of the administrators of your application.

Using a Different Database Provider

If you do not want to use SQL Server or Azure SQL Database, the source code can be modified to use a different Entity Framework Core 2.1 database provider. Refer to the Entity Framework Core documentation for more information.

Newsblast.Server

The database connection is handled in Program.cs and Models/Configuration.cs.

Newsblast.Shared

The database connection is handled in Data/NewsblastContext.cs.

Newsblast.Web

The database connection is handled in Startup.cs.

Logging

Newsblast.Server saves logging information to Newsblast.Server.log. You may wish to prune it every so often to prevent unnecessary storage space usage.