Skip to content

Commit 4905f1d

Browse files
committed
Update readme with self-hosting steps and updated links/badges
1 parent fe6c6bb commit 4905f1d

File tree

2 files changed

+80
-103
lines changed

2 files changed

+80
-103
lines changed

README.md

+79-102
Original file line numberDiff line numberDiff line change
@@ -12,29 +12,31 @@
1212
<a href="https://github.com/denverquane/amongusdiscord/graphs/contributors" alt="Contributors">
1313
<img src="https://img.shields.io/github/contributors/denverquane/amongusdiscord" />
1414
</a>
15-
<a href="https://discord.gg/ZkqZSWF" alt="Contributors">
15+
<a href="https://discord.gg/ZkqZSWF" alt="Discord Link">
1616
<img src="https://img.shields.io/discord/754465589958803548?logo=discord" />
1717
</a>
1818
</p>
1919
<p align="center">
20-
<a href="https://discord.gg/ZkqZSWF" alt="Contributors">
20+
<a href="pulls" alt="Pulls">
2121
<img src="https://img.shields.io/docker/pulls/denverquane/amongusdiscord.svg" />
2222
</a>
23-
<a href="https://discord.gg/ZkqZSWF" alt="Contributors">
23+
<a href="stars" alt="Stars">
2424
<img src="https://img.shields.io/docker/stars/denverquane/amongusdiscord.svg" />
2525
</a>
2626
</p>
2727
<p align="center">
28-
<img alt="GitHub release (latest SemVer)" src="https://img.shields.io/github/v/release/denverquane/automuteus">
28+
<img alt="GitHub release" src="https://img.shields.io/github/v/release/denverquane/automuteus">
2929
</p>
3030

3131
<p align="center">
32-
<a href=https://discord.com/api/oauth2/authorize?client_id=753795015830011944&permissions=267746384&scope=bot/>
32+
<a href="https://discord.com/api/oauth2/authorize?client_id=753795015830011944&permissions=267746384&scope=bot"/>
3333
<img src="https://github.com/denverquane/automuteus/blob/master/assets/BotProfilePicture.png?raw=true", width=100>
34+
</p>
35+
</p>
36+
<p align="center">
37+
<a href="https://discord.com/api/oauth2/authorize?client_id=753795015830011944&permissions=267746384&scope=bot" alt="invite">
38+
<img alt="Invite Link" src="https://img.shields.io/static/v1?label=bot&message=invite%20me&color=purple">
3439
</a>
35-
<div align="center">
36-
^ Invite Me! ^
37-
</div>
3840
</p>
3941

4042
# AutoMuteUs (BETA)
@@ -47,150 +49,125 @@ Works in conjunction with [amonguscapture](https://github.com/denverquane/amongu
4749

4850
Have any questions, concerns, bug reports, or just want to chat? Join the discord at https://discord.gg/ZkqZSWF!
4951

50-
# Basic Requirements
52+
# ⚠️ Basic Requirements ⚠️
5153

52-
1. **The Capture application only supports the NON-BETA OFFICIAL STEAM release of the game**
53-
2. This Capture program must be run on a Windows PC. The program **CANNOT** be run directly on mobile phones, so you will need 1 PC player per match.
54+
1. The Capture application only supports the **Non-Beta Official Steam** release of the game
55+
2. The Capture application must be run on a Windows PC. The program **CANNOT** be run directly on mobile phones, so you will need 1 or more players on PC in every match.
5456

55-
# Installation Video (click the image):
57+
# Quickstart and Demo (click the image):
5658

5759
[![Installation](https://img.youtube.com/vi/LUptOv5ohNc/0.jpg)](https://youtu.be/LUptOv5ohNc)
5860

59-
# Installation
61+
# Usage and Commands
6062

61-
If you followed all the steps in the video above, you're done with the installation and can start using the bot, or see the
62-
Usage/Commands sections below! If you prefer text instructions over videos, follow all the instructions below instead.
63+
To start a bot game in the current channel, type the following `.au` command in Discord after inviting the bot:
6364

64-
## Pre-Installation Steps, Important!!!
65+
```
66+
.au new
67+
# Starts a game, and allows users to react to emojis to link to their in-game players
68+
```
6569

66-
1. Create an Application and Bot account for your Discord Server (requires Admin privileges on the Server in question).
67-
- Follow the instructions [HERE](https://github.com/denverquane/amongusdiscord/blob/master/BOT_README.md)
70+
Get Playing!
6871

69-
Now follow either the `Easiest` install, or the `Install From Source`:
72+
If you want to view command usage or see the available options, type `.au` or `.au help` in your Discord channel.
7073

71-
## Easiest:
74+
## Commands
7275

73-
1. [Download the latest release executable (`.exe`) and `final.txt`](https://github.com/denverquane/amongusdiscord/releases) for this discord bot.
74-
If you don't see one for the current version, then simply create a new text document called `final.txt`, and put `DISCORD_BOT_TOKEN =` as the contents.
75-
2. Paste the Bot Token you obtained in the pre-installation into the `final.txt` file, after the `=` sign for the `DISCORD_BOT_TOKEN`.
76-
3. Run the executable from step 1, either by double-clicking or using `./amongusdiscord.exe` in a terminal window.
77-
4. [Download the latest `amonguscapture.exe`](https://github.com/denverquane/amonguscapture/releases).
78-
5. Start Among Us and host a game or join a game.
79-
6. Automatically start capture by issuing the `.au n` (or `.au new`) command to the bot via Discord. The bot will send you a Direct Message with a link like: aucapture://<host>:8123/<connectcode>?insecure. Click this link and the capture executable will automatically be launched.
80-
Alternatively, manually start the capture executable from step 4 and type in the Connect Code from amongusdiscord.exe (should be 8 characters long), Connect, and issue the bot the command .au n(ew) via Discord.
81-
7. Have fun and enjoy!
76+
The Discord Bot uses the `.au` prefix for any commands
8277

83-
Congrats, if you followed the instructions correctly, the bot should now be running! See the Sample Usage section below for details.
78+
| Command | Alias | Arguments | Description | Example |
79+
| -------------- | ------- | ----------- | --------------------------------------------------------------------------------------------------------------- | ---------------------------------- |
80+
| `.au help` | `.au h` | None | Print help info and command usage | |
81+
| `.au new` | `.au n` | None | Start a new game in the current text channel. Optionally accepts the room code and region | `.au n CODE eu` |
82+
| `.au track` | `.au t` | VC Name | Tell Bot to use a single voice channel for mute/unmute, and ignore any other channels | `.au t Test Voice` |
83+
| `.au link` | `.au l` | @name color | Manually link a discord user to their in-game color | `.au l @Soup cyan` |
84+
| `.au refresh` | `.au r` | None | Remake the bot's status message entirely, in case it ends up too far up in the chat. | |
85+
| `.au end` | `.au e` | None | End the game entirely, and stop tracking players. Unmutes all and resets state | |
86+
| `.au unlink` | `.au u` | @name | Manually unlink a player | `.au u @player` |
87+
| `.au settings` | `.au s` | | View and change settings for the bot, such as the command prefix or mute behavior | |
88+
| `.au force` | `.au f` | stage | Force a transition to a stage if you encounter a problem in the state | `.au f task` or `.au f d`(discuss) |
89+
| `.au pause` | `.au p` | | Pause the bot, and don't let it automute anyone until unpaused. **will not un-mute muted players, be careful!** | |
90+
| `.au log` | | message | Issue a small log message that will help you find the message later, if a problem occurs | `.au log Something bad happened` |
91+
92+
*In addition to handful of more secretive Easter Egg commands...*
93+
94+
# Self-Hosting
95+
96+
If you would prefer to self-host the bot, the steps for doing so are provided below.
97+
Self-hosting requires robust knowledge and troubleshooting capability for Docker/Docker-compose, unRAID, Heroku, and any other networking and routing config specific to your hosting solution.
8498

85-
## Install From Source:
99+
As such, **we recommend that the majority of users take advantage of our Verified bot**. The link to invite our bot can be found here:
86100

87-
1. [Install Go 1.15.2](https://golang.org/dl/go1.15.2.windows-amd64.msi), but any version of Go 1.12+ should work.
88-
2. Clone the repository using `git clone https://github.com/denverquane/amongusdiscord`.
89-
3. Navigate to the directory with `cd amongusdiscord`, and then build the executable using `go build -o amongusdiscord.exe main.go`.
90-
4. Proceed to steps 2-5 of the `Easiest` install section above.
101+
<a href="https://discord.com/api/oauth2/authorize?client_id=753795015830011944&permissions=267746384&scope=bot" alt="invite">
102+
<img alt="Invite Link" src="https://img.shields.io/static/v1?label=bot&message=invite%20me&color=purple">
103+
</a>
104+
105+
If you are certain that you would prefer to self-host the bot, please follow any of the guides detailed below.
106+
107+
## Pre-Installation Steps, Important!
108+
109+
- Create an Application and Bot account (requires Admin privileges on the Server in question). [Instructions here](https://github.com/denverquane/amongusdiscord/blob/master/BOT_README.md)
91110

92-
## Remote Hosted Bot Requirements
111+
Now follow any of the specific hosting options provided below:
93112

94-
Remote usage (Capture app and bot app running on separate networks) is possible with AutoMuteUs however it is recommended only for those familiar with advanced networking topics such as Static IPs, Dynamic DNS, and Port Mappings. If you are not already comfortable with these topics it is not recommended that you attempt to set up remote use. If you wish to have remote users run the capture app then you will need the following:
113+
## Docker Compose:
95114

96-
1. The computer hosting the bot must have a static IP on your local network (preferably outside your DHCP pool, or have a reserved IP address).
97-
2. You must create a port mapping on your router to map port 8123 to your bot host (UniFi users please note that the current UniFi controller does not enable new port mappings by default)
98-
3. Unless you have a static IP from your ISP you will need a dynamic DNS service such as DuckDNS, Afraid, or No-IP. You will also need that service set up to automatically update your IP when it changes.
115+
Docker compose is the simplest and recommended method for self-hosting AutoMuteUs, but it does require an existing physical machine or VPS to run on.
99116

100-
## Docker
117+
There is a `docker-compose.yml` file in this repository that will provide all the consituent components to run AutoMuteUs.
101118

102-
You can also run the discord portion using docker if you prefer, it simply needs the port `8123` exposed, and you should provide your `DISCORD_BOT_TOKEN` as an env variable.
103-
Example:
104-
`docker run -p 8123:8123 -e DISCORD_BOT_TOKEN=<YourTokenHere> denverquane/amongusdiscord`
119+
### Steps:
120+
- Install Docker and Docker Compose on the machine you will be using to host AutoMuteUs
121+
- Download the `docker-compose.yml` from this repository, and create a `.env` file in the same directory that will contain your Environment Variables. On Linux/UNIX systems you can use `touch .env` to create this file, but a template `sample.env` is provided in this repository for reference.
122+
- Provide your specific Environment Variables in the `.env` file, as relevant to your configuration. Please see the Environment Variables reference further down in this Readme for details, as well as the `sample.env` provided.
123+
- Run `docker-compose pull`. This will download the latest built Docker images from Dockerhub that are required to run AutoMuteUs.
124+
- Run `docker-compose up -d` to start all the containers required for AutoMuteUs to function. The containers will now be running in the background, but you can view the logs for the containers using `docker-compose logs`, or `docker-compose logs -f` to follow along as new log entries are generated.
105125

106126
## unRAID
107127

108-
AutoMuteUs is now available in Community Applications for unRAID. Install the Community Applications plugin for unRAID then search for AutoMuteUs in the Apps section. Fill out the template with the Docker Environment Variables that are detailed here and in the template.
128+
unRAID hosting steps are are not updated for v3.0+ of AutoMuteUs, and as such is not supported at this time.
129+
130+
## Heroku
131+
132+
Heroku hosting steps are are not updated for v3.0+ of AutoMuteUs, and as such is not supported at this time.
109133

110134
## Environment Variables
111135

136+
### Required
137+
112138
- `DISCORD_BOT_TOKEN`: The Bot Token used by the bot to authenticate with Discord.
113-
- `DISCORD_BOT_TOKEN_2`: (Optional) A second Bot Token to be used to distribute the mute/deafen requests to Discord.
114-
If you play in larger groups of 8+ people, this is recommended to not be rate-limited (delayed) by Discord when rounds change!
139+
- `REDIS_ADDRESS`: The host and port at which your Redis database instance is accessible. Ex: `192.168.1.42:6379`
115140

116-
### Advanced. Only configure these variables if you know what you're doing
141+
### Optional
117142

143+
- `DISCORD_BOT_TOKEN_2`: A second Bot Token to be used to distribute the mute/deafen requests to Discord.
144+
If you play in larger groups of 8+ people, this is recommended to not be rate-limited (delayed) by Discord when rounds change!
118145
- `EMOJI_GUILD_ID`: If your bot is a member of multiple guilds, this ID can be used to specify the single guild that it should use for emojis (no need to add the emojis to ALL servers).
119-
- `PORT`: The **internal** port the Bot will use for incoming Socket.io communications. Defaults to 8123.
146+
- `PORT`: The **internal** port the Bot will use for incoming socket.io communications. Defaults to 8123.
120147
- `HOST`: The **externally-accessible URL** for the discord bot. For example, `http://test.com:8123`.
121148
This is used to provide the linking URI to the capture, via the Direct Message the bot sends you when typing `.au new`.
122149
**You must specify `http://` or `https://` accordingly, and specify the port if non-8123. For example, `https://your-app.herokuapp.com:443`**
123150
- `SERVICE_PORT`: Port used for graceful shutdowns and stats via HTTP GET. Defaults to 5000
124151
- `CONFIG_PATH`: Alternate filesystem path for guild and user config files. Defaults to `./`
125152
- `LOG_PATH`: Filesystem path for log files. Defaults to `./`
126-
- `CAPTURE_TIMEOUT`: How many seconds of no capture events received before the Bot will terminate the associated game/connection. Defaults to 600 seconds.
153+
- `CAPTURE_TIMEOUT`: How many seconds of no capture events received before the Bot will terminate the associated game/connection. Defaults to 36000 seconds.
127154

128155
### HIGHLY advanced. Probably don't ever touch these!
129156

130157
- `NUM_SHARDS`: Num shards provided to the Discord API.
131158
- `SHARD_ID`: Shard ID used to identify with the Discord API. Needs to be strictly less than `NUM_SHARDS`
132159

133-
## Deploy to Heroku
134-
135-
[![Deploy](https://www.herokucdn.com/deploy/button.svg)](https://heroku.com/deploy)
136-
137-
1. Navigate to your Heroku app dashboard
138-
2. Go to Settings
139-
3. Click on Reveal Config Vars
140-
4. Ensure the following is populated
141-
DISCORD_BOT_TOKEN = xxx
142-
EXT_PORT = 443
143-
GOVERSION = 1.15
144-
PORT = 443
145-
HOST = https://your-app.herokuapp.com:443
146-
(Click on open app if you are unsure. Be sure to remove the space and ensure no slash "/" at the end, this fixed it for me)
147-
148-
5. Check the app's logs. See if it is up and running with no issues.
149-
6. You should see your bot in discord. Issue a .au n(ew) command and click the link in the direct message from the bot. If you haven't already download the capture app and .Net Core install.
150-
7. The link should connect the capture.exe to your bot and Discord will show your game in it's assigned text channel.
151-
152-
# Sample Usage
153-
154-
To start the bot in the current channel, type the following `.au` command in Discord:
155-
156-
```
157-
.au new
158-
# Starts a game, and allows users to react to emojis to link to their in-game players
159-
```
160-
161-
Get Playing!
162-
163-
If you want to view command usage or see the available options, type `.au` or `.au help` in your Discord channel.
164-
165-
# Bot Commands
166-
167-
The Discord Bot uses the `.au` prefix for any commands
168-
169-
| Command | Alias | Arguments | Description | Example |
170-
| -------------- | ------- | ----------- | --------------------------------------------------------------------------------------------------------------- | ---------------------------------- |
171-
| `.au help` | `.au h` | None | Print help info and command usage | |
172-
| `.au new` | `.au n` | None | Start a new game in the current text channel. Optionally accepts the room code and region | `.au n CODE eu` |
173-
| `.au track` | `.au t` | VC Name | Tell Bot to use a single voice channel for mute/unmute, and ignore any other channels | `.au t Test Voice` |
174-
| `.au link` | `.au l` | @name color | Manually link a discord user to their in-game color | `.au l @Soup cyan` |
175-
| `.au refresh` | `.au r` | None | Remake the bot's status message entirely, in case it ends up too far up in the chat. | |
176-
| `.au end` | `.au e` | None | End the game entirely, and stop tracking players. Unmutes all and resets state | |
177-
| `.au unlink` | `.au u` | @name | Manually unlink a player | `.au u @player` |
178-
| `.au settings` | `.au s` | | View and change settings for the bot, such as the command prefix or mute behavior | |
179-
| `.au force` | `.au f` | stage | Force a transition to a stage if you encounter a problem in the state | `.au f task` or `.au f d`(discuss) |
180-
| `.au pause` | `.au p` | | Pause the bot, and don't let it automute anyone until unpaused. **will not un-mute muted players, be careful!** | |
181-
| `.au log` | | message | Issue a small log message that will help you find the message later, if a problem occurs | `.au log Something bad happened` |
182-
183160
# Similar Projects
184161

185162
- [Imposter](https://github.com/molenzwiebel/Impostor): Similar bot that uses private Discord channels instead of mute/deafen. Also uses a dummy player joining the game and "spectating" to get game information; no capture needed (although loses the 10th player slot).
186163

187164
- [AmongUsBot](https://github.com/alpharaoh/AmongUsBot): Without their original Python program
188-
with a lot of the OCR/Discord functionality, I never would have even thought of this idea! Not currently maintained
165+
with a lot of the OCR/Discord functionality, I never would have even thought of this idea! **Not currently maintained**
189166

190167
- [amongcord](https://github.com/pedrofracassi/amongcord): A great program for tracking player status and auto mute/unmute in Among Us.
191168
Their project works like a traditional Discord bot; very easy installation!
192169

193-
- [Silence Among Us](https://github.com/tanndev/silence-among-us#silence-among-us): Another bot quite similar to this one, which also uses AmongUsCapture. Now in early-access with a publicly-hosted instance.
170+
- [Silence Among Us](https://github.com/tanndev/silence-among-us#silence-among-us): Another bot quite similar to this one, which also uses AmongUsCapture. Now in early-access with a publicly-hosted instance!
194171

195172
# Troubleshooting
196173

TODO.org

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
TODO private channel for posting round transitions/debug info
22
TODO @the bot if you forget command prefix or the like
33
TODO add emoji reactions to the help message to also work as commands
4-
TODO bot presence
4+
TODO include docker compose file and sample env

0 commit comments

Comments
 (0)