documentation/assets/js/51.f11b077a.js

1 line
5.6 KiB
JavaScript

(window.webpackJsonp=window.webpackJsonp||[]).push([[51],{311:function(e,t,a){"use strict";a.r(t);var s=a(15),r=Object(s.a)({},(function(){var e=this,t=e._self._c;return t("ContentSlotsDistributor",{attrs:{"slot-key":e.$parent.slotKey}},[t("h1",{attrs:{id:"upgrading-php"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#upgrading-php"}},[e._v("#")]),e._v(" Upgrading PHP")]),e._v(" "),t("p",[e._v("This documentation includes instructions for upgrading your system to the latest version of PHP. Please reference the\ntable below to check what version you need for your version of Pterodactyl.")]),e._v(" "),t("table",[t("thead",[t("tr",[t("th",[e._v("Panel Version")]),e._v(" "),t("th",[e._v("PHP Version")])])]),e._v(" "),t("tbody",[t("tr",[t("td",[e._v("1.0.0 - 1.2.0")]),e._v(" "),t("td",[e._v("7.3, 7.4")])]),e._v(" "),t("tr",[t("td",[e._v("1.3.0+")]),e._v(" "),t("td",[e._v("7.4, 8.0")])]),e._v(" "),t("tr",[t("td",[e._v("1.8.0+")]),e._v(" "),t("td",[e._v("7.4, 8.0, 8.1")])]),e._v(" "),t("tr",[t("td",[e._v("1.11.0 - 1.11.3")]),e._v(" "),t("td",[e._v("8.0, 8.1")])]),e._v(" "),t("tr",[t("td",[e._v("1.11.4+")]),e._v(" "),t("td",[e._v("8.1, 8.2, 8.3")])]),e._v(" "),t("tr",[t("td",[e._v("1.11.10+")]),e._v(" "),t("td",[e._v("8.2, 8.3")])])])]),e._v(" "),t("h2",{attrs:{id:"install-php"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#install-php"}},[e._v("#")]),e._v(" Install PHP")]),e._v(" "),t("p",[e._v("In order to install PHP 8.3, you will need to run the following command. Please keep in mind different operating systems\nmay have slightly different requirements for how this command is formatted.")]),e._v(" "),t("div",{staticClass:"language-bash extra-class"},[t("pre",{pre:!0,attrs:{class:"language-bash"}},[t("code",[t("span",{pre:!0,attrs:{class:"token comment"}},[e._v("# Add additional repository for PHP")]),e._v("\nadd-apt-repository "),t("span",{pre:!0,attrs:{class:"token parameter variable"}},[e._v("-y")]),e._v(" ppa:ondrej/php\n"),t("span",{pre:!0,attrs:{class:"token function"}},[e._v("apt")]),e._v(" "),t("span",{pre:!0,attrs:{class:"token parameter variable"}},[e._v("-y")]),e._v(" update\n"),t("span",{pre:!0,attrs:{class:"token function"}},[e._v("apt")]),e._v(" "),t("span",{pre:!0,attrs:{class:"token parameter variable"}},[e._v("-y")]),e._v(" "),t("span",{pre:!0,attrs:{class:"token function"}},[e._v("install")]),e._v(" php8.3 php8.3-"),t("span",{pre:!0,attrs:{class:"token punctuation"}},[e._v("{")]),e._v("cli,gd,mysql,pdo,mbstring,tokenizer,bcmath,xml,fpm,curl,zip"),t("span",{pre:!0,attrs:{class:"token punctuation"}},[e._v("}")]),e._v("\n")])])]),t("h2",{attrs:{id:"update-composer"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#update-composer"}},[e._v("#")]),e._v(" Update Composer")]),e._v(" "),t("p",[e._v("As of "),t("code",[e._v("Panel@1.3.0")]),e._v(" we require "),t("code",[e._v("composer")]),e._v(" v2. To update composer you will need to run the following command which will\nperform the composer self-update process and move you over to version 2.")]),e._v(" "),t("div",{staticClass:"language-bash extra-class"},[t("pre",{pre:!0,attrs:{class:"language-bash"}},[t("code",[t("span",{pre:!0,attrs:{class:"token function"}},[e._v("composer")]),e._v(" self-update "),t("span",{pre:!0,attrs:{class:"token parameter variable"}},[e._v("--2")]),e._v("\n")])])]),t("h2",{attrs:{id:"webserver-configuration"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#webserver-configuration"}},[e._v("#")]),e._v(" Webserver Configuration")]),e._v(" "),t("tabs",[t("tab",{attrs:{name:"NGINX"}},[t("p",[e._v("After upgrading to PHP 8.3, you will most likely need to update your NGINX configuration. Your configuration file\nis most likely called "),t("code",[e._v("pterodactyl.conf")]),e._v(" and located in the "),t("code",[e._v("/etc/nginx/sites-available/")]),e._v(" directory, or if on CentOS,\n"),t("code",[e._v("/etc/nginx/conf.d/")]),e._v(".")]),e._v(" "),t("p",[e._v("Make sure to update the path in the command below to reflect the actual location of your configuration file.")]),e._v(" "),t("div",{staticClass:"language-bash extra-class"},[t("pre",{pre:!0,attrs:{class:"language-bash"}},[t("code",[t("span",{pre:!0,attrs:{class:"token function"}},[e._v("sed")]),e._v(" "),t("span",{pre:!0,attrs:{class:"token parameter variable"}},[e._v("-i")]),e._v(" "),t("span",{pre:!0,attrs:{class:"token parameter variable"}},[e._v("-e")]),e._v(" "),t("span",{pre:!0,attrs:{class:"token string"}},[e._v("'s/php[7|8].[0-9]-fpm.sock/php8.3-fpm.sock/'")]),e._v(" /etc/nginx/sites-available/pterodactyl.conf\n")])])]),t("p",[e._v("Once you have edited the file run the command below to reload nginx and apply your changes.")]),e._v(" "),t("div",{staticClass:"language-bash extra-class"},[t("pre",{pre:!0,attrs:{class:"language-bash"}},[t("code",[e._v("systemctl reload nginx\n")])])])]),e._v(" "),t("tab",{attrs:{name:"Apache"}},[t("p",[e._v("Run the commands below to disable all previous PHP versions and enable PHP 8.3 when serving requests.")]),e._v(" "),t("div",{staticClass:"language-bash extra-class"},[t("pre",{pre:!0,attrs:{class:"language-bash"}},[t("code",[t("span",{pre:!0,attrs:{class:"token comment"}},[e._v("# Hint: a2dismod = a2_disable_module 🤯")]),e._v("\na2dismod php*\n\n"),t("span",{pre:!0,attrs:{class:"token comment"}},[e._v("# Hint: a2enmod = a2_enable_module 🤯")]),e._v("\na2enmod php8.3\n\n")])])])])],1),e._v(" "),t("h3",{attrs:{id:"return-to-the-1-x-x-upgrade-guide"}},[t("a",{staticClass:"header-anchor",attrs:{href:"#return-to-the-1-x-x-upgrade-guide"}},[e._v("#")]),e._v(" "),t("RouterLink",{attrs:{to:"/panel/1.0/upgrade/1.0.html#fetch-updated-files"}},[e._v("Return to the 1.X.X Upgrade Guide")])],1)],1)}),[],!1,null,null,null);t.default=r.exports}}]);