docs(pterodactyl): added a section on installing the cog and explaining what the project is

This commit is contained in:
Seaswimmer 2024-03-02 12:29:10 -05:00
parent 3a52efeac0
commit 8fdf9eb239
Signed by untrusted user: cswimr
GPG key ID: B8953EC01E5C4063

View file

@ -9,6 +9,35 @@ The steps should be basically identical for other panels, but screenshots will l
If in doubt, contact your host's support. If in doubt, contact your host's support.
/// ///
## Installing the cog
This project is a [cog](https://discordpy.readthedocs.io/en/stable/ext/commands/cogs.html) made for use with *specifically* instances of [Red-DiscordBot](https://github.com/Cog-Creators/Red-DiscordBot).
See the [Red documentation](https://docs.discord.red/en/stable/install_guides/index.html) for information on how to run an instance of Red. Once you've got it running, come back here.
/// admonition | `[p]` is your bot's prefix
type: tip
///
Now, load the Downloader cog:
```
[p]load downloader
```
The Downloader cog allows you to add Git repositories to your bot in order to download cogs from them.
Now, use Downloader to add my repository to your bot:
```
[p]repo add sea-cogs https://www.coastalcommits.com/SeaswimmerTheFsh/SeaCogs
```
Now, install the Pterodactyl cog:
```
[p]cog install sea-cogs pterodactyl
[p]load pterodactyl
```
## Creating a sub-user ## Creating a sub-user
This is **optional**, but highly recommended, for security reasons. This is **optional**, but highly recommended, for security reasons.
@ -17,7 +46,7 @@ Navigate to your `Users` page, and click the `New User` button.
Type in an email address, and press `Select all permissions`. Type in an email address, and press `Select all permissions`.
*The bot doesn't need all of the permissions you just gave it to function, we'll deal with that in a moment.* *The bot doesn't need all of the permissions you just gave it to function, we'll deal with that in a moment.*
![image](/img/pterodactyl/setup/1.png) ![image](../img/pterodactyl/setup/1.png)
Now, you'll need to check the email you just entered into the subusers page, and create an account. I won't cover this, as it'll change depending on what host you're using. Now, you'll need to check the email you just entered into the subusers page, and create an account. I won't cover this, as it'll change depending on what host you're using.
@ -27,7 +56,7 @@ Moving on, the bot doesn't need all of the permissions you just gave it. This po
["websocket.connect","control.read-console","control.console","control.start","control.stop","control.restart","startup.read","startup.update","settings.rename","settings.reinstall"] ["websocket.connect","control.read-console","control.console","control.start","control.stop","control.restart","startup.read","startup.update","settings.rename","settings.reinstall"]
``` ```
![image](/img/pterodactyl/setup/2.png) ![image](../img/pterodactyl/setup/2.png)
## Getting an API Key ## Getting an API Key
@ -35,15 +64,15 @@ Moving on, the bot doesn't need all of the permissions you just gave it. This po
Navigate to your sub-user account's `API Credentials` page. Navigate to your sub-user account's `API Credentials` page.
![image](/img/pterodactyl/setup/3.png) ![image](../img/pterodactyl/setup/3.png)
Create a new API key. Create a new API key.
![image](/img/pterodactyl/setup/4.png) ![image](../img/pterodactyl/setup/4.png)
You don't have to specify an allowed IP if you don't want to, but I recommend it. If you chose to, you'll need to retrieve your bot's IP address. You can do this through SSH or through a cog like [AAA3A's IP cog](https://github.com/AAA3A-AAA3A/AAA3A-cogs). You don't have to specify an allowed IP if you don't want to, but I recommend it. If you chose to, you'll need to retrieve your bot's IP address. You can do this through SSH or through a cog like [AAA3A's IP cog](https://github.com/AAA3A-AAA3A/AAA3A-cogs).
![image](/img/pterodactyl/setup/5.png) ![image](../img/pterodactyl/setup/5.png)
Now, use the `[p]set api` command on your bot to add the API key. Now, use the `[p]set api` command on your bot to add the API key.
The format is as follows: The format is as follows:
@ -53,7 +82,7 @@ The format is as follows:
# Keys and Tokens: api_key ptlc_... # Keys and Tokens: api_key ptlc_...
``` ```
![image](/img/pterodactyl/setup/6.png) ![image](../img/pterodactyl/setup/6.png)
## Getting server information ## Getting server information
@ -61,21 +90,21 @@ There's some other information that the Pterodactyl cog needs to function.
First, get the base url for your panel. This does not include any extra information, like server ids, or whatnot. In my case, I'm using `https://mc.bloom.host/`. First, get the base url for your panel. This does not include any extra information, like server ids, or whatnot. In my case, I'm using `https://mc.bloom.host/`.
![image](/img/pterodactyl/setup/7.png) ![image](../img/pterodactyl/setup/7.png)
Use the `[p]pterodactyl config url` command to set the URL the cog will use. Use the `[p]pterodactyl config url` command to set the URL the cog will use.
In my case, I'd use `-pterodactyl config url https://mc.bloom.host/`. In my case, I'd use `-pterodactyl config url https://mc.bloom.host/`.
![image](/img/pterodactyl/setup/8.png) ![image](../img/pterodactyl/setup/8.png)
Now, we need to get the id of your server. Navigate to the `Settings` page in your panel. Now, we need to get the id of your server. Navigate to the `Settings` page in your panel.
![image](/img/pterodactyl/setup/9.png) ![image](../img/pterodactyl/setup/9.png)
Use the `[p]pterodactyl config serverid` command to add the server id to the bot. Use the `[p]pterodactyl config serverid` command to add the server id to the bot.
In my case, I'd use `-pterodactyl config serverid ad712016-df3d-47a5-b1df-6b71baf50340`. In my case, I'd use `-pterodactyl config serverid ad712016-df3d-47a5-b1df-6b71baf50340`.
![image](/img/pterodactyl/setup/10.png) ![image](../img/pterodactyl/setup/10.png)
Once you've done all of this, you should see a connection message in the bot's logs. Now, we need to configure some other things. Once you've done all of this, you should see a connection message in the bot's logs. Now, we need to configure some other things.
See the [Configuration](configuration.md) page for more information. See the [Configuration](configuration.md) page for more information.