documentation/assets/js/21.aba75f57.js

1 line
19 KiB
JavaScript

(window.webpackJsonp=window.webpackJsonp||[]).push([[21],{362:function(e,t,a){e.exports=a.p+"assets/img/daemon_configuration_example.7d1665c4.png"},390:function(e,t,a){"use strict";a.r(t);var s=a(48),n=Object(s.a)({},(function(){var e=this,t=e.$createElement,s=e._self._c||t;return s("ContentSlotsDistributor",{attrs:{"slot-key":e.$parent.slotKey}},[s("h1",{attrs:{id:"installation"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#installation"}},[e._v("#")]),e._v(" Installation")]),e._v(" "),s("div",{staticClass:"custom-block danger"},[s("p",{staticClass:"custom-block-title"},[e._v("This Software is Abandoned")]),e._v(" "),s("p",[e._v("This documentation is for "),s("strong",[e._v("abandoned software")]),e._v(" which does not recieve any security updates or support\nfrom the community. This documentation has been left accessible for historial reasons.")]),e._v(" "),s("p",[e._v("You should be installing and using "),s("RouterLink",{attrs:{to:"/wings/1.0/installing.html"}},[e._v("Wings")]),e._v(" in production environments with\n"),s("RouterLink",{attrs:{to:"/panel/1.0/getting_started.html"}},[e._v("Pterodactyl Panel 1.0")]),e._v(".")],1)]),e._v(" "),s("div",{staticClass:"custom-block warning"},[s("p",{staticClass:"custom-block-title"},[e._v("WARNING")]),e._v(" "),s("p",[e._v("This specific software is for Pterodactyl v0.7 and "),s("strong",[e._v("must not be used for Pterodactyl v1.0")]),e._v(". If you have installed 1.0 you should use "),s("RouterLink",{attrs:{to:"/wings/1.0/installing.html"}},[e._v("Wings")]),e._v(" instead.")],1)]),e._v(" "),s("p"),s("div",{staticClass:"table-of-contents"},[s("ul",[s("li",[s("a",{attrs:{href:"#supported-systems"}},[e._v("Supported Systems")])]),s("li",[s("a",{attrs:{href:"#system-requirements"}},[e._v("System Requirements")])]),s("li",[s("a",{attrs:{href:"#dependencies"}},[e._v("Dependencies")]),s("ul",[s("li",[s("a",{attrs:{href:"#installing-docker"}},[e._v("Installing Docker")])]),s("li",[s("a",{attrs:{href:"#installing-nodejs"}},[e._v("Installing Nodejs")])])])]),s("li",[s("a",{attrs:{href:"#installing-daemon-software"}},[e._v("Installing Daemon Software")])]),s("li",[s("a",{attrs:{href:"#configure-daemon"}},[e._v("Configure Daemon")])]),s("li",[s("a",{attrs:{href:"#starting-the-daemon"}},[e._v("Starting the Daemon")]),s("ul",[s("li",[s("a",{attrs:{href:"#daemonizing-using-systemd"}},[e._v("Daemonizing (using systemd)")])])])])])]),s("p"),e._v(" "),s("h2",{attrs:{id:"supported-systems"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#supported-systems"}},[e._v("#")]),e._v(" Supported Systems")]),e._v(" "),s("table",[s("thead",[s("tr",[s("th",[e._v("Operating System")]),e._v(" "),s("th",[e._v("Version")]),e._v(" "),s("th",{staticStyle:{"text-align":"center"}},[e._v("Supported")]),e._v(" "),s("th",[e._v("Notes")])])]),e._v(" "),s("tbody",[s("tr",[s("td",[s("strong",[e._v("Ubuntu")])]),e._v(" "),s("td",[e._v("18.04")]),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td",[e._v("Documentation written assuming Ubuntu 18.04 as the base OS.")])]),e._v(" "),s("tr",[s("td"),e._v(" "),s("td",[s("RouterLink",{attrs:{to:"/community/installation-guides/daemon/ubuntu2004.html"}},[e._v("20.04")])],1),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td")]),e._v(" "),s("tr",[s("td",[s("strong",[e._v("CentOS")])]),e._v(" "),s("td",[s("RouterLink",{attrs:{to:"/community/installation-guides/daemon/centos7.html"}},[e._v("7")])],1),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("⚠️")]),e._v(" "),s("td",[e._v("Extra repos are required")])]),e._v(" "),s("tr",[s("td"),e._v(" "),s("td",[s("RouterLink",{attrs:{to:"/community/installation-guides/daemon/centos8.html"}},[e._v("8")])],1),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td")]),e._v(" "),s("tr",[s("td",[s("strong",[e._v("Debian")])]),e._v(" "),s("td",[s("RouterLink",{attrs:{to:"/community/installation-guides/daemon/debian9.html"}},[e._v("9")])],1),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td")]),e._v(" "),s("tr",[s("td"),e._v(" "),s("td",[s("RouterLink",{attrs:{to:"/community/installation-guides/daemon/debian10.html"}},[e._v("10")])],1),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td")])])]),e._v(" "),s("h2",{attrs:{id:"system-requirements"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#system-requirements"}},[e._v("#")]),e._v(" System Requirements")]),e._v(" "),s("p",[e._v("In order to run the Daemon you will need a system capable of running Docker containers. Most VPS and almost all\ndedicated servers should be capable of running Docker, but there are edge cases.")]),e._v(" "),s("p",[e._v("If your provider makes use of "),s("code",[e._v("Virtuozzo")]),e._v(", "),s("code",[e._v("OpenVZ")]),e._v(" (or "),s("code",[e._v("OVZ")]),e._v("), or "),s("code",[e._v("LXC")]),e._v(" then you will most likely be unable to\nrun the Daemon. If you are unsure what your host is using there are a couple of options. The easiest is to check\ntheir website, or reach out to their support team.")]),e._v(" "),s("p",[e._v("If you want to take a different approach, try using "),s("code",[e._v("lscpu")]),e._v(" and checking what the virtualization type listed is. An\nexample of this is shown below which shows my hypervisor running with full virtualization — this means it will\nsupport Docker without issues. If you see "),s("code",[e._v("KVM")]),e._v(" for the vendor, chances are you're fine as well.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[e._v("dane@daemon:~$ lscpu "),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("|")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("grep")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token string"}},[e._v("'vendor\\|type'")]),e._v("\nHypervisor vendor: VMware\nVirtualization type: full\n")])])]),s("p",[e._v("If that doesn't work for some reason, or you're still unsure, you can also run the command below and as long as it\ndoesn't report "),s("code",[e._v("Xen")]),e._v(" or "),s("code",[e._v("LXC")]),e._v(" you're probably okay to continue.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[e._v("dane@daemon:~$ "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("sudo")]),e._v(" dmidecode -s system-manufacturer\nVMware, Inc.\n")])])]),s("h2",{attrs:{id:"dependencies"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#dependencies"}},[e._v("#")]),e._v(" Dependencies")]),e._v(" "),s("p",[e._v("Pterodactyl's Daemon requires the following dependencies be installed on your system in order for it to operate.")]),e._v(" "),s("ul",[s("li",[e._v("Docker")]),e._v(" "),s("li",[e._v("Nodejs ("),s("code",[e._v("v10")]),e._v(", "),s("code",[e._v("v12")]),e._v(", higher versions likely work, but are untested)")]),e._v(" "),s("li",[s("code",[e._v("node-gyp")])]),e._v(" "),s("li",[s("code",[e._v("tar")])]),e._v(" "),s("li",[s("code",[e._v("unzip")])]),e._v(" "),s("li",[s("code",[e._v("make")]),e._v(", "),s("code",[e._v("gcc")]),e._v(" ("),s("code",[e._v("gcc-c++")]),e._v(" on CentOS), "),s("code",[e._v("g++")])]),e._v(" "),s("li",[s("code",[e._v("python")])])]),e._v(" "),s("h3",{attrs:{id:"installing-docker"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#installing-docker"}},[e._v("#")]),e._v(" Installing Docker")]),e._v(" "),s("p",[e._v("For a quick install of Docker CE, you can execute the command below:")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[s("span",{pre:!0,attrs:{class:"token function"}},[e._v("curl")]),e._v(" -sSL https://get.docker.com/ "),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("|")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token assign-left variable"}},[e._v("CHANNEL")]),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("=")]),e._v("stable "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("bash")]),e._v("\n")])])]),s("p",[e._v("If you would rather do a manual installation, please reference the official Docker documentation for how to install Docker CE on your server. Some quick links\nare listed below for commonly supported systems.")]),e._v(" "),s("ul",[s("li",[s("a",{attrs:{href:"https://docs.docker.com/install/linux/docker-ce/ubuntu/#install-docker-ce",target:"_blank",rel:"noopener noreferrer"}},[e._v("Ubuntu"),s("OutboundLink")],1)]),e._v(" "),s("li",[s("a",{attrs:{href:"https://docs.docker.com/install/linux/docker-ce/centos/#install-docker-ce",target:"_blank",rel:"noopener noreferrer"}},[e._v("CentOS"),s("OutboundLink")],1)]),e._v(" "),s("li",[s("a",{attrs:{href:"https://docs.docker.com/install/linux/docker-ce/debian/#install-docker-ce",target:"_blank",rel:"noopener noreferrer"}},[e._v("Debian"),s("OutboundLink")],1)])]),e._v(" "),s("div",{staticClass:"custom-block warning"},[s("p",{staticClass:"custom-block-title"},[e._v("Check your Kernel")]),e._v(" "),s("p",[e._v("Please be aware that some hosts install a modified kernel that does not support important docker features. Please\ncheck your kernel by running "),s("code",[e._v("uname -r")]),e._v(". If your kernel ends in "),s("code",[e._v("-xxxx-grs-ipv6-64")]),e._v(" or "),s("code",[e._v("-xxxx-mod-std-ipv6-64")]),e._v(" you're\nprobably using a non-supported kernel. Check our "),s("RouterLink",{attrs:{to:"/daemon/0.6/kernel_modifications.html"}},[e._v("Kernel Modifications")]),e._v(" guide for details.")],1)]),e._v(" "),s("h4",{attrs:{id:"start-docker-on-boot"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#start-docker-on-boot"}},[e._v("#")]),e._v(" Start Docker on Boot")]),e._v(" "),s("p",[e._v("If you are on an operating system with systemd (Ubuntu 16+, Debian 8+, CentOS 7+) run the command below to have Docker start when you boot your machine.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[e._v("systemctl "),s("span",{pre:!0,attrs:{class:"token builtin class-name"}},[e._v("enable")]),e._v(" docker\n")])])]),s("h4",{attrs:{id:"enabling-swap"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#enabling-swap"}},[e._v("#")]),e._v(" Enabling Swap")]),e._v(" "),s("p",[e._v("On most systems, docker will be unable to setup swap space, you can check if this is the case by running "),s("code",[e._v("docker info")]),e._v(".\nIf it outputs "),s("code",[e._v("WARNING: No swap limit support")]),e._v(" near the bottom, this is the case. Enabling swap is completely optional,\nbut we recommended doing it if you will be hosting for others, and to prevent OOM errors.")]),e._v(" "),s("p",[e._v("To do so, open "),s("code",[e._v("/etc/default/grub")]),e._v(" as a root user, and find the line starting with "),s("code",[e._v("GRUB_CMDLINE_LINUX_DEFAULT")]),e._v(". Make\nsure the line includes "),s("code",[e._v("swapaccount=1")]),e._v(".")]),e._v(" "),s("p",[e._v("After doing that, simply run "),s("code",[e._v("sudo update-grub")]),e._v(" followed by "),s("code",[e._v("sudo reboot")]),e._v(" to restart the server and have swap enabled.\nBelow is an example of what the line should look like, "),s("em",[e._v("do not copy this line verbatium, it often has additional\nOS specific parameters.")])]),e._v(" "),s("div",{staticClass:"language-text extra-class"},[s("pre",{pre:!0,attrs:{class:"language-text"}},[s("code",[e._v('GRUB_CMDLINE_LINUX_DEFAULT="swapaccount=1"\n')])])]),s("h3",{attrs:{id:"installing-nodejs"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#installing-nodejs"}},[e._v("#")]),e._v(" Installing Nodejs")]),e._v(" "),s("p",[e._v("NodeJS is also super easy to install! Simply run the command below to make the package accessible to your system.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[s("span",{pre:!0,attrs:{class:"token function"}},[e._v("curl")]),e._v(" -sL https://deb.nodesource.com/setup_10.x "),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("|")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("sudo")]),e._v(" -E "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("bash")]),e._v(" -\n"),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("apt")]),e._v(" -y "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("install")]),e._v(" nodejs "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("make")]),e._v(" gcc g++\n")])])]),s("div",{staticClass:"custom-block tip"},[s("p",{staticClass:"custom-block-title"},[e._v("Other OS Distributions")]),e._v(" "),s("p",[e._v("If you are using CentOS, "),s("a",{attrs:{href:"https://nodejs.org/en/download/package-manager/#enterprise-linux-and-fedora",target:"_blank",rel:"noopener noreferrer"}},[e._v("please follow these instructions"),s("OutboundLink")],1),e._v(". Ubuntu and Debian users may also follow the "),s("a",{attrs:{href:"https://nodejs.org/en/download/package-manager/#debian-and-ubuntu-based-linux-distributions",target:"_blank",rel:"noopener noreferrer"}},[e._v("official\ninstructions provided by Nodejs"),s("OutboundLink")],1),e._v(".")])]),e._v(" "),s("h2",{attrs:{id:"installing-daemon-software"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#installing-daemon-software"}},[e._v("#")]),e._v(" Installing Daemon Software")]),e._v(" "),s("div",{staticClass:"custom-block danger"},[s("p",{staticClass:"custom-block-title"},[e._v("This Software is Abandoned")]),e._v(" "),s("p",[e._v("This documentation is for "),s("strong",[e._v("abandoned software")]),e._v(" which does not recieve any security updates or support\nfrom the community. This documentation has been left accessible for historial reasons.")]),e._v(" "),s("p",[e._v("You should be installing and using "),s("RouterLink",{attrs:{to:"/wings/1.0/installing.html"}},[e._v("Wings")]),e._v(" in production environments with\n"),s("RouterLink",{attrs:{to:"/panel/1.0/getting_started.html"}},[e._v("Pterodactyl Panel 1.0")]),e._v(".")],1)]),e._v(" "),s("p",[e._v("The first step for installing the daemon is to make sure we have the required directory structure setup. To do so,\nrun the commands below.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[s("span",{pre:!0,attrs:{class:"token function"}},[e._v("mkdir")]),e._v(" -p /srv/daemon /srv/daemon-data\n"),s("span",{pre:!0,attrs:{class:"token builtin class-name"}},[e._v("cd")]),e._v(" /srv/daemon\n")])])]),s("div",{staticClass:"custom-block warning"},[s("p",{staticClass:"custom-block-title"},[e._v("OVH/SYS Servers")]),e._v(" "),s("p",[e._v("If you are using a server provided by OVH or SoYouStart please be aware that your main drive space is probably allocated to\n"),s("code",[e._v("/home")]),e._v(", and not "),s("code",[e._v("/")]),e._v(" by default. Please consider using "),s("code",[e._v("/home/daemon-data")]),e._v(" for server data. This can be easily\nset when creating the node.")])]),e._v(" "),s("p",[e._v("The next step is to download the software and unpack the archive.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[s("span",{pre:!0,attrs:{class:"token function"}},[e._v("curl")]),e._v(" -L https://github.com/pterodactyl/daemon/releases/download/v0.6.13/daemon.tar.gz "),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("|")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("tar")]),e._v(" --strip-components"),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("=")]),s("span",{pre:!0,attrs:{class:"token number"}},[e._v("1")]),e._v(" -xzv\n")])])]),s("p",[e._v("Finally, we need to install the dependencies that allow the Daemon to run properly. This command will most likely\ntake a few minutes to run, please do not interrupt it.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[s("span",{pre:!0,attrs:{class:"token function"}},[e._v("npm")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("install")]),e._v(" --only"),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("=")]),e._v("production --no-audit --unsafe-perm\n")])])]),s("h2",{attrs:{id:"configure-daemon"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#configure-daemon"}},[e._v("#")]),e._v(" Configure Daemon")]),e._v(" "),s("p",[e._v("Once you have installed the daemon and required components, the next step is to create a node on your installed Panel\nOnce you have done that there will be a tab called Configuration when you view the node.")]),e._v(" "),s("p",[e._v("Simply copy and paste the code block and paste it into a file called "),s("code",[e._v("core.json")]),e._v(" in "),s("code",[e._v("/srv/daemon/config")]),e._v(" and save it.\nYou may also use the Auto-Deployment feature rather than manually creating the files.")]),e._v(" "),s("p",[s("img",{attrs:{src:a(362),alt:""}})]),e._v(" "),s("h2",{attrs:{id:"starting-the-daemon"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#starting-the-daemon"}},[e._v("#")]),e._v(" Starting the Daemon")]),e._v(" "),s("p",[e._v("To start your daemon simply move into the daemon directory and run the command below which will start the daemon in\nforeground mode. Once you are done, use "),s("code",[e._v("CTRL+C")]),e._v(" to terminate the process. Depending on your server's internet connection\npulling and starting the Daemon for the first time may take a few minutes.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[s("span",{pre:!0,attrs:{class:"token function"}},[e._v("sudo")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("npm")]),e._v(" start\n")])])]),s("h3",{attrs:{id:"daemonizing-using-systemd"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#daemonizing-using-systemd"}},[e._v("#")]),e._v(" Daemonizing (using systemd)")]),e._v(" "),s("p",[e._v("Running Pterodactyl Daemon in the background is a simple task, just make sure that it runs without errors before doing\nthis. Place the contents below in a file called "),s("code",[e._v("wings.service")]),e._v(" in the "),s("code",[e._v("/etc/systemd/system")]),e._v(" directory.")]),e._v(" "),s("div",{staticClass:"language-text extra-class"},[s("pre",{pre:!0,attrs:{class:"language-text"}},[s("code",[e._v("[Unit]\nDescription=Pterodactyl Wings Daemon\nAfter=docker.service\n\n[Service]\nUser=root\n#Group=some_group\nWorkingDirectory=/srv/daemon\nLimitNOFILE=4096\nPIDFile=/var/run/wings/daemon.pid\nExecStart=/usr/bin/node /srv/daemon/src/index.js\nRestart=on-failure\nStartLimitInterval=600\n\n[Install]\nWantedBy=multi-user.target\n")])])]),s("p",[e._v("Then, run the commands below to reload systemd and start the daemon.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[e._v("systemctl "),s("span",{pre:!0,attrs:{class:"token builtin class-name"}},[e._v("enable")]),e._v(" --now wings\n")])])])])}),[],!1,null,null,null);t.default=n.exports}}]);