Skip to content

Instantly share code, notes, and snippets.

View HenrySpartGlobal's full-sized avatar

Henry HenrySpartGlobal

  • https://www.worldpay.com/
  • London
View GitHub Profile
@HenrySpartGlobal
HenrySpartGlobal / deploy-new-bot.yml
Last active September 27, 2024 08:32
Auto Deployment of Discord Bot with Systemd and GitHub Actions
# Author: Henry Koleoso
# Put these two files in .github/workflows/
# Prerequisites:
# SSH Key pair - Private key in GitHub Secrets, Public key in /root/.ssh/authorized_keys on your server
# Discord Bot token - In GitHub Secrets or Environment Variables.
# This file is the workflow that handles the initial setup of your Discord bot.
# This job should be run only ONCE. Changes in 'create-systemctl-service' are appended to the systemd.service file, not overwritten so the file will be invalid!
# If you make a mistake, and need to run this job more than once, navigate to /etc/systemd/system