Skip to content

Commit 82f61cc

Browse files
committed
Bump PHP 8.2
1 parent 7289402 commit 82f61cc

File tree

7 files changed

+44
-17
lines changed

7 files changed

+44
-17
lines changed

_docs/developer/software_and_system_design/coding_style_guide/php.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ redirect_from:
55
- /developer/coding_style_guide/php
66
---
77

8-
__Minimum Version__: 8.1
8+
__Minimum Version__: 8.2
99

1010
For PHP, we use a foundation of [PSR-1](https://www.php-fig.org/psr/psr-1/) and
1111
[PSR-12](https://www.php-fig.org/psr/psr-12/), with some slight modifications on

_docs/developer/testing/install_php.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,12 +8,20 @@ you will need to have PHP installed on your host machine first.
88

99
### Linux & WSL:
1010

11-
*If you're distro cannot find the correct package or installs the wrong version you may have to specify php8.1 in each package name*
11+
*If you're distro cannot find the correct package or installs the wrong version you may have to specify php8.2 in each package name*
1212

1313
```bash
1414
sudo apt-get update
1515
sudo apt-get install -y php php-curl php-xml php-mbstring
1616
```
17+
18+
*You may need to install the PHP PPA for certain versions of PHP*
19+
20+
```bash
21+
sudo add-apt-repository ppa:ondrej/php
22+
sudo apt update
23+
```
24+
1725
### MacOS
1826

1927
```bash
@@ -25,11 +33,11 @@ default.
2533

2634
### Windows
2735

28-
Download [php 8.1](https://windows.php.net/download/) as a zip file under the thread safe category. Then extract the contents of the zip to a folder, and add the path to that folder to your path system variable. It's suggested that one extracts the contents of the zip to a folder called `php`, which can be put at `C:\php` for simplicity. You can then add `C:\php` to your path system environment variable.
36+
Download [php 8.2](https://windows.php.net/download/) as a zip file under the thread safe category. Then extract the contents of the zip to a folder, and add the path to that folder to your path system variable. It's suggested that one extracts the contents of the zip to a folder called `php`, which can be put at `C:\php` for simplicity. You can then add `C:\php` to your path system environment variable.
2937

3038
-------------
3139

32-
Verify you have PHP installed correctly, submitty requires a version greater than 7.0
40+
Verify you have PHP installed correctly, submitty requires at least version 8.2
3341

3442
```bash
3543
php -v

_docs/sysadmin/configuration/course_creation.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ you can follow these [instructions](ansible_course_creation) to create a course
6060
need to restart fpm to ensure that the webpage sees the change:_
6161

6262
```
63-
sudo service php8.1-fpm restart
63+
sudo service php8.2-fpm restart
6464
```
6565

6666
_Note: Depending on your version of Ubuntu, your version of php fpm will be different._
@@ -122,7 +122,7 @@ you can follow these [instructions](ansible_course_creation) to create a course
122122
123123
_Note: You will sometimes need to restart PHP-FPM after adding a course._
124124
```
125-
sudo service php8.1-fpm restart
125+
sudo service php8.2-fpm restart
126126
```
127127
128128

_docs/sysadmin/installation/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ You can use these [instructions](/sysadmin/installation/ansible).
7575
4. Edit PHP Settings
7676

7777
We recommend for security that you modify your PHP installation and disable certain PHP functions.
78-
To do this, edit `/etc/php/8.1/fpm/php.ini` and find the entry for `disable_functions` and make sure the list of
78+
To do this, edit `/etc/php/8.2/fpm/php.ini` and find the entry for `disable_functions` and make sure the list of
7979
disabled functions contains:
8080

8181
```

_docs/sysadmin/installation/system_customization.md

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -162,7 +162,7 @@ By default, PHP only allows 20 files to be uploaded at a time.
162162
This limit is probably sufficient, but to change this limit, edit:
163163

164164
```
165-
/etc/php/8.1/fpm/php.ini
165+
/etc/php/8.2/fpm/php.ini
166166
```
167167

168168
and modify the variable:
@@ -174,7 +174,7 @@ max_file_uploads = 20
174174

175175
Then restart PHP
176176
```
177-
systemctl reload php8.1-fpm
177+
systemctl reload php8.2-fpm
178178
```
179179

180180
## Allowing Large Student File Upload Submissions
@@ -187,7 +187,7 @@ value, view/edit this file:
187187

188188

189189
```
190-
/etc/php/8.1/fpm/php.ini
190+
/etc/php/8.2/fpm/php.ini
191191
```
192192

193193
_Note: Depending on your version of Ubuntu, your version of php fpm will be different._
@@ -207,14 +207,14 @@ And restart apache:
207207

208208
```
209209
sudo systemctl restart apache2.service
210-
sudo systemctl restart php8.1-fpm.service
210+
sudo systemctl restart php8.2-fpm.service
211211
```
212212

213213
and/or
214214

215215
```
216216
sudo service apache2 restart
217-
sudo service php8.1-fpm restart
217+
sudo service php8.2-fpm restart
218218
```
219219

220220
_Note: Depending on your version of Ubuntu, your version of php fpm will be different._
@@ -229,7 +229,7 @@ in the `config.json`, for example:
229229
```
230230

231231
If you are having difficulty with student upload size, you can modify the
232-
following in `/etc/php/8.1/fpm/php.ini`:
232+
following in `/etc/php/8.2/fpm/php.ini`:
233233

234234
```
235235
memory_limit
@@ -245,7 +245,7 @@ students are using the system at once.
245245
## Tune the performance of the website to handle a large number of users
246246

247247

248-
Reading the PHP memory limit from `/etc/php/8.1/fpm/php.ini`
248+
Reading the PHP memory limit from `/etc/php/8.2/fpm/php.ini`
249249

250250
```
251251
memory_limit = <MEMORY LIMIT>
@@ -262,14 +262,14 @@ restart apache and php-fpm:
262262

263263
```
264264
sudo systemctl restart apache2.service
265-
sudo systemctl restart php8.1-fpm.service
265+
sudo systemctl restart php8.2-fpm.service
266266
```
267267

268268

269269
#### PHP-FPM settings using the static process manager
270270

271271

272-
Adjust the following settings in `/etc/php/8.1/fpm/pool.d/submitty.conf`.
272+
Adjust the following settings in `/etc/php/8.2/fpm/pool.d/submitty.conf`.
273273

274274
We have found that the following settings work well for a production
275275
server with approximately 2000 students. The commented out line is
@@ -292,7 +292,7 @@ can be used to calculate a `pm.max_children` value for your server
292292
#### PHP-FPM settings using the dynamic process manager
293293

294294

295-
Adjust the following settings in `/etc/php/8.1/fpm/pool.d/submitty.conf`.
295+
Adjust the following settings in `/etc/php/8.2/fpm/pool.d/submitty.conf`.
296296

297297
The commented out line is the default value. Please read the documentation
298298
to determine values that are appropriate for your own system.
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
---
2+
title: v26.01.00 > Upgrading to PHP 8.2
3+
category: System Administrator > Installation Version Notes
4+
---
5+
6+
Release [v26.01.00](https://github.com/Submitty/Submitty/releases/v26.01.00)
7+
includes an update to PHP from 8.1 to 8.2.
8+
9+
A migration exists which will do the following:
10+
1. Uninstall PHP 8.1
11+
2. Install PHP 8.2
12+
3. Configure PHP 8.2's `php.ini` file for a normal system installation
13+
4. Copy `submitty.conf` from `/etc/php/8.1/fpm/pool.d` to `/etc/php/8.2/fpm/pool.d`
14+
15+
`/etc/php/8.1` is not deleted or modified in any way during this process.
16+
17+
Ensure any custom configuration from `/etc/php/8.1` is copied over to `/etc/php/8.2`.
18+
Once complete, `/etc/php/8.1` can be deleted.

navtreedata.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,7 @@ var NAVTREE =
156156
[ "Ansible Server Installation", "/sysadmin/installation/ansible", null ],
157157
[ "Version Notes", "/sysadmin/installation/version_notes/index", [
158158
[ "Overview", "/sysadmin/installation/version_notes/index", null],
159+
[ "v26.01.00", "/sysadmin/installation/version_notes/v26.01.00", null ],
159160
[ "v25.07.01", "/sysadmin/installation/version_notes/v25.07.01", null ],
160161
[ "v23.12.02", "/sysadmin/installation/version_notes/v23.12.02", null ],
161162
[ "v23.07.00", "/sysadmin/installation/version_notes/v23.07.00", null ],

0 commit comments

Comments
 (0)