documentation/assets/js/20.e5a0bcca.js
2022-06-12 00:20:24 +00:00

1 line
17 KiB
JavaScript

(window.webpackJsonp=window.webpackJsonp||[]).push([[20],{339:function(e,t,a){e.exports=a.p+"assets/img/wings_configuration_example.9f3fdd0b.png"},366:function(e,t,a){e.exports=a.p+"assets/img/node_allocations.323d67f2.png"},424: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:"installing-wings"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#installing-wings"}},[e._v("#")]),e._v(" Installing Wings")]),e._v(" "),s("p",[e._v("Wings is the next generation server control plane from Pterodactyl. It has been rebuilt from the\nground up using Go and lessons learned from our first Nodejs Daemon.")]),e._v(" "),s("div",{staticClass:"custom-block warning"},[s("p",{staticClass:"custom-block-title"},[e._v("WARNING")]),e._v(" "),s("p",[e._v("You should only install Wings if you are running "),s("strong",[e._v("Pterodactyl 1.x")]),e._v(". Do not install this software\nfor previous versions of Pterodactyl.")])]),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("p",[e._v("The following is a list of supported operating systems. Please be aware that this is not an exhaustive list,\nthere is a high probability that you can run the software on other Linux distributions without much effort.\nYou are responsible for determining which packages may be necessary on those systems. There is also a very\nhigh probability that new releases of the supported OSes below will work just fine, you are not restricted to\nonly the versions listed below.")]),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",[e._v("20.04")]),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",[e._v("7")]),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td")]),e._v(" "),s("tr",[s("td"),e._v(" "),s("td",[e._v("8")]),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td",[e._v("Note that CentOS 8 is EOL. Use Rocky or Alma Linux.")])]),e._v(" "),s("tr",[s("td",[s("strong",[e._v("Debian")])]),e._v(" "),s("td",[e._v("9")]),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td")]),e._v(" "),s("tr",[s("td"),e._v(" "),s("td",[e._v("10")]),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td")]),e._v(" "),s("tr",[s("td"),e._v(" "),s("td",[e._v("11")]),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("✅")]),e._v(" "),s("td")]),e._v(" "),s("tr",[s("td",[s("strong",[e._v("Windows")])]),e._v(" "),s("td",[e._v("All")]),e._v(" "),s("td",{staticStyle:{"text-align":"center"}},[e._v("❌")]),e._v(" "),s("td",[e._v("This software will not run in Windows environments.")])])])]),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("To run Wings, you will need a Linux 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("When your provider uses "),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(" virtualization, you will most likely be unable to\nrun Wings. Some providers have made the necessary changes for nested virtualization to support Docker. Ask your provider's support team to make sure. KVM is guaranteed to work.")]),e._v(" "),s("p",[e._v("The easiest way to check is to type "),s("code",[e._v("systemd-detect-virt")]),e._v(".\nIf the result doesn't contain "),s("code",[e._v("OpenVZ")]),e._v(" or"),s("code",[e._v("LXC")]),e._v(", it should be fine. The result of "),s("code",[e._v("none")]),e._v(" will appear when running dedicated hardware without any virtualization.")]),e._v(" "),s("p",[e._v("Should that not work for some reason, or you're still unsure, you can also run the command below.")]),e._v(" "),s("div",{staticClass:"language-bash extra-class"},[s("pre",{pre:!0,attrs:{class:"language-bash"}},[s("code",[e._v("dane@pterodactyl:~$ "),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("ul",[s("li",[e._v("curl")]),e._v(" "),s("li",[e._v("Docker")])]),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(" --now 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 by default. You can confirm this by running "),s("code",[e._v("docker info")]),e._v(" and looking for the output of "),s("code",[e._v("WARNING: No swap limit support")]),e._v(" near the bottom.")]),e._v(" "),s("p",[e._v("Enabling swap is entirely optional, but we recommended doing it if you will be hosting for others and to prevent OOM errors.")]),e._v(" "),s("p",[e._v("To enable swap, 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(" somewhere inside the double-quotes.")]),e._v(" "),s("p",[e._v("After that, 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 verbatim. It often has additional OS-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("div",{staticClass:"custom-block tip"},[s("p",{staticClass:"custom-block-title"},[e._v("GRUB Configuration")]),e._v(" "),s("p",[e._v("Some Linux distros may ignore "),s("code",[e._v("GRUB_CMDLINE_LINUX_DEFAULT")]),e._v(". Therefore you might have to use "),s("code",[e._v("GRUB_CMDLINE_LINUX")]),e._v(" instead should the default one not work for you.")])]),e._v(" "),s("h2",{attrs:{id:"installing-wings-2"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#installing-wings-2"}},[e._v("#")]),e._v(" Installing Wings")]),e._v(" "),s("p",[e._v("The first step for installing Wings is to ensure we have the required directory structure setup. To do so,\nrun the commands below, which will create the base directory and download the wings executable.")]),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 /etc/pterodactyl\n"),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("curl")]),e._v(" -L -o /usr/local/bin/wings "),s("span",{pre:!0,attrs:{class:"token string"}},[e._v('"https://github.com/pterodactyl/wings/releases/latest/download/wings_linux_$([[ "'),s("span",{pre:!0,attrs:{class:"token variable"}},[s("span",{pre:!0,attrs:{class:"token variable"}},[e._v("$(")]),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("uname")]),e._v(" -m"),s("span",{pre:!0,attrs:{class:"token variable"}},[e._v(")")])]),e._v('"')]),e._v(" "),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("==")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token string"}},[e._v('"x86_64"')]),e._v(" "),s("span",{pre:!0,attrs:{class:"token punctuation"}},[e._v("]")]),s("span",{pre:!0,attrs:{class:"token punctuation"}},[e._v("]")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("&&")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token builtin class-name"}},[e._v("echo")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token string"}},[e._v('"amd64"')]),e._v(" "),s("span",{pre:!0,attrs:{class:"token operator"}},[e._v("||")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token builtin class-name"}},[e._v("echo")]),e._v(" "),s("span",{pre:!0,attrs:{class:"token string"}},[e._v('"arm64"')]),s("span",{pre:!0,attrs:{class:"token punctuation"}},[e._v(")")]),e._v('"\n'),s("span",{pre:!0,attrs:{class:"token function"}},[e._v("chmod")]),e._v(" u+x /usr/local/bin/wings\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("h2",{attrs:{id:"configure"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#configure"}},[e._v("#")]),e._v(" Configure")]),e._v(" "),s("p",[e._v("Once you have installed Wings and the required components, the next step is to create a node on your installed Panel. Go to your Panel administrative view, select Nodes from the sidebar, and on the right side click Create New button.")]),e._v(" "),s("p",[e._v("After you have created a node, click on it and there will be a tab called Configuration. Copy the code block content, paste it into a new file called "),s("code",[e._v("config.yml")]),e._v(" in "),s("code",[e._v("/etc/pterodactyl")]),e._v(" and save it.")]),e._v(" "),s("p",[e._v("Alternatively, you can click on the Generate Token button, copy the bash command and paste it into your terminal.")]),e._v(" "),s("p",[s("img",{attrs:{src:a(339),alt:"example image of wings configuration"}})]),e._v(" "),s("div",{staticClass:"custom-block warning"},[s("p",{staticClass:"custom-block-title"},[e._v("WARNING")]),e._v(" "),s("p",[e._v("When your Panel is using SSL, the Wings must also have one created for its FQDN. See "),s("RouterLink",{attrs:{to:"/tutorials/creating_ssl_certificates.html"}},[e._v("Creating SSL Certificates")]),e._v(" documentation page for how to create these certificates before continuing.")],1)]),e._v(" "),s("h3",{attrs:{id:"starting-wings"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#starting-wings"}},[e._v("#")]),e._v(" Starting Wings")]),e._v(" "),s("p",[e._v("To start Wings, simply run the command below, which will start it in a debug mode. Once you confirmed that it is running without errors, use "),s("code",[e._v("CTRL+C")]),e._v(" to terminate the process and daemonize it by following the instructions below. Depending on your server's internet connection pulling and starting Wings 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(" wings --debug\n")])])]),s("p",[e._v("You may optionally add the "),s("code",[e._v("--debug")]),e._v(" flag to run Wings in debug mode.")]),e._v(" "),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 Wings 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\nRequires=docker.service\nPartOf=docker.service\n\n[Service]\nUser=root\nWorkingDirectory=/etc/pterodactyl\nLimitNOFILE=4096\nPIDFile=/var/run/wings/daemon.pid\nExecStart=/usr/local/bin/wings\nRestart=on-failure\nStartLimitInterval=180\nStartLimitBurst=30\nRestartSec=5s\n\n[Install]\nWantedBy=multi-user.target\n")])])]),s("p",[e._v("Then, run the commands below to reload systemd and start Wings.")]),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")])])]),s("h3",{attrs:{id:"node-allocations"}},[s("a",{staticClass:"header-anchor",attrs:{href:"#node-allocations"}},[e._v("#")]),e._v(" Node Allocations")]),e._v(" "),s("p",[e._v("Allocation is a combination of IP and Port that you can assign to a server. Each created server must have at least one allocation. The allocation would be the IP address of your network interface. In some cases, such as when behind NAT, it would be the internal IP. To create new allocations go to Nodes > your node > Allocation.")]),e._v(" "),s("p",[s("img",{attrs:{src:a(366),alt:"example image of node allocations"}})]),e._v(" "),s("p",[e._v("Type "),s("code",[e._v("hostname -I | awk '{print $1}'")]),e._v(" to find the IP to be used for the allocation. Alternatively, you can type "),s("code",[e._v('ip addr | grep "inet "')]),e._v(" to see all your available interfaces and IP addresses. Do not use 127.0.0.1 for allocations.")])])}),[],!1,null,null,null);t.default=n.exports}}]);