From 17114cf51d83e2c7130ff5ef50fca6d2bb4441ff Mon Sep 17 00:00:00 2001 From: miraai Date: Fri, 5 Aug 2016 18:55:08 +0200 Subject: [PATCH] Update Linux Guide.md --- docs/guides/Linux Guide.md | 76 +++++++++++++++----------------------- 1 file changed, 30 insertions(+), 46 deletions(-) diff --git a/docs/guides/Linux Guide.md b/docs/guides/Linux Guide.md index 52196dc0..77713a46 100644 --- a/docs/guides/Linux Guide.md +++ b/docs/guides/Linux Guide.md @@ -5,28 +5,30 @@ ######Keep this helpful video handy [Linux Setup Video][Linux Setup Video] (thanks to klincheR) it contains how to set up the Digital Ocean droplet aswell. -####Setting up NadekoBot Assuming you have followed the link above to created an account in Digital Ocean and video to set up the bot until you get the `IP address and root password (in email)` to login, its time to begin. #### Prerequisites - Download [PuTTY][PuTTY] - Download [CyberDuck][CyberDuck] + +**If you are setting up NadekoBot locally, prerequisites up^ are NOT needed and you can skip the steps involving them.** -#### Follow these steps +####Setting up NadekoBot - **Open PuTTY.exe** that you downloaded before, and paste or enter your `IP address` and then click **Open**. If you entered your Droplets IP address correctly, it should show **login as:** in a newly opened window. - Now for **login as:**, type `root` and hit enter. - It should then, ask for password, type the `root password` you have received in your **email address registered with Digital Ocean**, then hit Enter. -*(as you are running it for the first time, it will most likely to ask you to change your root password, for that, type the "password you received through email", hit Enter, enter a "new password", hit Enter and confirm that "new password" again.* +*(as you are running it for the first time, it will most likely to ask you to change your root password, for that, type the "password you received through email", hit Enter, enter a "new password", hit Enter and confirm that "new password" again.)* **SAVE that new password somewhere safe not just in mind**. After you done that, you are ready to write commands. **Copy and just paste** using **mouse right-click** (it should paste automatically) +####Installing Mono ######MONO (Source: [Mono Source][Mono Source]) -**1) Installing Mono** +**1)** `sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF` `echo "deb http://download.mono-project.com/repo/debian wheezy main" | sudo tee /etc/apt/sources.list.d/mono-xamarin.list` @@ -59,17 +61,7 @@ sudo tee -a /etc/apt/sources.list.d/mono-xamarin.list` **Type** `y` **hit Enter** - -**4)** -Opus Voice Codec - -`sudo apt-get install libopus0 opus-tools` - -**Type** `y` **hit Enter** - -**5)** -`sudo apt-get install libopus-dev` - +####Mono Fix **In case you are having issues with Mono where you get a random string and the bot won't run, do this:** `sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-keys 3FA7E0328081BFF6A14DA29AA6A19B38D3D831EF` @@ -77,10 +69,18 @@ Opus Voice Codec `apt-get install ca-certificates-mono` `mozroots --import --sync` +####Installing Opus Voice Codec + +- Opus Voice Codec + +`sudo apt-get install libopus0 opus-tools` + +**Type** `y` **hit Enter** + +`sudo apt-get install libopus-dev` ####FFMPEG -**6)** `apt-get install ffmpeg` **Type** `y` **hit Enter** @@ -108,53 +108,42 @@ In case you are not able to install it with installer ^up there, follow these st ####Uncomplicated Firewall UFW -**7)** +- Install UFW `apt-get install ufw` **it is most likely to have it already installed so if you see it is already installed, check with following command, and/or enable it** -**8)** `ufw status` - -**9)** `ufw enable` **Type** `y` **hit Enter** -**10)** `sudo ufw allow ssh` - - -**11)** -Unzip +####Installing Unzip `apt-get install unzip` -**12)** -TMUX +####Installing TMUX `apt-get install tmux` **Type** `y` **hit Enter** ####Importing certs -**13)** + `certmgr -ssl https://discordapp.com` -**14)** `certmgr -ssl https://gateway.discord.gg` Type `yes` and hit Enter **(three times - as it will ask for three times)** - -**15)** -Create a new folder “nadeko” or anything you prefer +####Creating Nadeko folder +- Create a new folder “nadeko” or anything you prefer `mkdir nadeko` -**16)** -Move to “nadeko” folder (note `cd --` to go back the directory) +- Move to “nadeko” folder (note `cd --` to go back the directory) `cd nadeko` @@ -163,15 +152,12 @@ Move to “nadeko” folder (note `cd --` to go back the directory) Go to this link: [Releases][Releases] and **copy the zip file address** of the lalest version available, it should look like `https://github.com/Kwoth/NadekoBot/releases/download/vx.xx/NadekoBot.vx.x.zip` -**17)** Get the correct link, type `wget`, then *paste the link*, then hit **Enter**. `wget https://github.com/Kwoth/NadekoBot/releases/download/vx.xx/NadekoBot.vx.x.zip` **^Do not copy-paste it** -**18)** - Now we need to `unzip` the downloaded zip file and to do that, type the file name as it showed in your screen or just copy from the screen, should be like ` NadekoBot.vx.x.zip` `unzip NadekoBot.vx.x.zip` @@ -201,19 +187,19 @@ Now we need to `unzip` the downloaded zip file and to do that, type the file nam ####Running NadekoBot -Go back to **PuTTY**, `(hope its still running xD)` - -**19)** -Type/ Copy and hit **Enter**. +- Go back to **PuTTY**, `(hope its still running xD)` +- Type/ Copy and hit **Enter**. `tmux new -s nadeko` **^this will create a new session named “nadeko”** `(you can replace “nadeko” with anything you prefer and remember its your session name) so you can run the bot in background without having to keep running PuTTY in the background.` +- Enter your Nadeko folder `cd nadeko` -**20)** +- Start NadekoBot with mono + `mono NadekoBot.exe` **CHECK THE BOT IN DISCORD, IF EVERYTHING IS WORKING** @@ -228,13 +214,11 @@ Copy your CLIENT ID (that's in the same Developer page where you brought your to -If you want to **see the sessions** after logging back again, type `tmux ls`, and that will give you the list of sessions running. -If you want to **switch to/ see that session**, type `tmux a -t nadeko` (**nadeko** is the name of the session we created before so, replace **“nadeko”** with the session name you created.) - -**21)** -If you want to **kill** NadekoBot **session**, type `tmux kill-session -t nadeko` ####How to restart Nadeko with the server (for science) -**22)** -Open **PuTTY** and login as you have before, type `reboot` and hit Enter. + +- Open **PuTTY** and login as you have before, type `reboot` and hit Enter. ####Updating Nadeko