Skip to content

Commit 30a8029

Browse files
authored
PHRAS-4130 : upgrade mariadb to 5.11.11 (#4586)
* PHRAS-4130 : upgrade mariadb to 5.11.11 * Update CHANGELOG.md
1 parent fad3633 commit 30a8029

File tree

4 files changed

+82
-13
lines changed

4 files changed

+82
-13
lines changed

.env

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -522,6 +522,10 @@ MYSQL_QUERY_CACHE_SIZE=64M
522522
# @run
523523
MYSQL_KEY_BUFFER_SIZE=128M
524524

525+
# This Environment variable will run mariadb-upgrade is essential when mariadb version changes.
526+
# @run
527+
MARIADB_AUTO_UPGRADE=1
528+
525529
# --- DB Backup settings ---------------------------------------------------------------------------------------------
526530
# "db-backup" profile launch and run a container to cron database backups and backup file's rotation.
527531
# This container is based on the "alpine" image and use the "mysql-client" package to perform backups.

CHANGELOG.md

Lines changed: 76 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,71 @@
11
# CHANGELOG
22

3+
## 4.1.16
4+
5+
### Update Instructions
6+
7+
The ```docker compose``` stack bump version of the provided MariaDB.
8+
9+
Docker Compose does not cleanly stop MySQL by default.
10+
Therefore, an error can occur when restarting the DB after an update.
11+
see:https://github.com/MariaDB/mariadb-docker/issues/185
12+
13+
To cleanly stop MariaDB with docker compose, you can use the following command:
14+
```dc exec db /usr/bin/mysqladmin -uroot -p shutdown```
15+
16+
Performing a DB backup is recommended before starting the update procedure.
17+
You can use the db-backup profile included in the docker-compose.tools.yml file to perform the backup.
18+
19+
Added environement variable
20+
MARIADB_AUTO_UPGRADE variable is set to 1 (activated) by default and used to automate the upgrade of the mariadb system tables.
21+
When this environment variable is set, this will run the mariadb-upgrade⁠ (https://mariadb.com/kb/en/mariadb-upgrade/), if needed, so any changes in the MariaDB system tables required to expose new features will be made. This may impeed some downgrade options⁠. Unless the environment variable MARIADB_DISABLE_UPGRADE_BACKUP is set, there will be a backup of the system tables created as system_mysql_backup_*.sql.zst in the top level of the data directory to assist in the downgrade if needed.
22+
23+
Keep in mind, the provided MariaDB container in ```docker compose``` and stack is not ready for production as-is and requires adjustments.
24+
It is recommended to use an external, redundant service for the primary datastore.
25+
26+
#### Steps to Follow for Update docker compose stack
27+
28+
29+
1. Perform a backup of the application box and all databoxes published on your MariaDB server (the MariaDB database).
30+
2. Stop the MariaDB server with (adapt it with your credentials):
31+
```sh
32+
dc exec db /usr/bin/mysqladmin -uroot -p shutdown
33+
```
34+
3. Take down the Docker stack with:
35+
```sh
36+
dc down
37+
```
38+
4. Deploy the new Docker stack version.
39+
5. Bring up your stack with:
40+
```sh
41+
dc up -d
42+
```
43+
44+
**Note:** `dc` is a bash function aliasing `docker compose` with `.env` and `.env.local` values merged. See the [README.md](https://github.com/alchemy-fr/Phraseanet/blob/master/README.md#using-a-envlocal-method-for-custom-env-values) for more details.
45+
46+
47+
- **Phraseanet Migration Patch**:
48+
- A migration script for the configuration file is available. Run the following command in the setup container with Docker if the environment variable `PHRASEANET_UPGRADE=1` is set:
49+
```
50+
bin/setup system:upgrade
51+
```
52+
53+
54+
### Stack (Docker Compose and Helm)
55+
56+
- **MariaDB**: Bumped to 10.11.4
57+
58+
### Version Summary
59+
60+
- Bump MariaDB
61+
- todo
62+
63+
64+
### What's Changed
65+
66+
- WIP
67+
68+
__
369
## 4.1.15
470
571
### Update Instructions
@@ -15,7 +81,7 @@
1581
- Fixed status bit on persisted user's query.
1682
- Fixed issue with expose enabled publication during creation.
1783
18-
## What's Changed
84+
### What's Changed
1985
* PHRAS-3416 Phraseanet Translation by @nmaillat in https://github.com/alchemy-fr/Phraseanet/pull/4578
2086
* PHRAS-4123 : Prod - status preference saved : gives wrong answer after re-authentication by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4579
2187
* PHRAS-4115 Prod - Export window - Save File name choice made by the user by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4577
@@ -39,13 +105,12 @@ __
39105
- Correcting issue in patch 4111phras4106 where an error occurs if type is absent in IDP providers.
40106
41107
42-
## What's Changed
108+
### What's Changed
43109
* PHRAS-4120: bin/system upgrade - Upgrade fails on 4111phras4106 patch by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4574
44110
45111
46112
**Full Changelog**: https://github.com/alchemy-fr/Phraseanet/compare/4.1.13...4.1.14
47113
48-
49114
__
50115
## 4.1.13
51116
@@ -62,14 +127,13 @@ __
62127
- Remove www/.htacess from docker stack.
63128
- Remove Nginx access status.
64129
65-
## What's Changed
130+
### What's Changed
66131
* PHRAS-4117 remove gateway /status and /ping page direct access by @moctardiouf in https://github.com/alchemy-fr/Phraseanet/pull/4571
67132
* PHRAS-4119 exclude www/.htaccess file form docker stack in https://github.com/alchemy-fr/Phraseanet/pull/4573
68133
69134
70135
**Full Changelog**: https://github.com/alchemy-fr/Phraseanet/compare/4.1.12...4.1.13
71136
72-
73137
__
74138
## 4.1.12
75139
@@ -90,7 +154,7 @@ __
90154
91155
- **Phraseanet Base Image**: Bumped to 1.2.2
92156
93-
## What's Changed
157+
### What's Changed
94158
* PHRAS-4109: Language : Secure cookie seems to be always needing HTTPS by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4566
95159
* PHRAS-4112 bump base image to 1.2.1 / fix MP4Box by @moctardiouf in https://github.com/alchemy-fr/Phraseanet/pull/4567
96160
* PHRAS-4114 newrelic install fix by @nmaillat in https://github.com/alchemy-fr/Phraseanet/pull/4569
@@ -119,7 +183,7 @@ __
119183
- **Phraseanet Base Image**: Bumped to 1.2.0.
120184
- **Nginx**: adding quota on https requests, set it with environnements variables.
121185
122-
## What's Changed
186+
### What's Changed
123187
* PHRAS-4106 ignore openid groups by @jygaulier in https://github.com/alchemy-fr/Phraseanet/pull/4561
124188
* PHRAS-4093 Adding in UFRAW in Phraseanet base Image by @moctardiouf in https://github.com/alchemy-fr/Phraseanet/pull/4562
125189
* PHRAS-3588 Implement http request quota by type by @moctardiouf in https://github.com/alchemy-fr/Phraseanet/pull/4564
@@ -167,7 +231,7 @@ __
167231
- `imagePullPolicy` can now be set from `values.yaml`.
168232
- Release details: [Helm chart release 0.47.0](https://github.com/alchemy-fr/alchemy-helm-charts-repo/releases/tag/phraseanet-0.47.0)
169233
170-
## What's Changed
234+
### What's Changed
171235
* PHRAS-3416 : fix string in admin create subdef by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4534
172236
* PHRAS-3416 create subdefinition localisation by @nmaillat in https://github.com/alchemy-fr/Phraseanet/pull/4537
173237
* PHRAS-4094 Bump rabbitMQ version to 3.8.34 by @gjacobjn in https://github.com/alchemy-fr/Phraseanet/pull/4546
@@ -182,7 +246,7 @@ __
182246
* PHRAS-4104 Nginx bump 1.27.2 by @nmaillat in https://github.com/alchemy-fr/Phraseanet/pull/4557
183247
* PHRAS-4101: Update Range for Subdefinition Image Sizes by @nmaillat in https://github.com/alchemy-fr/Phraseanet/pull/4558
184248
185-
## New Contributors
249+
### New Contributors
186250
* @tacman made their first contribution in https://github.com/alchemy-fr/Phraseanet/pull/4552
187251
188252
**Full Changelog**: https://github.com/alchemy-fr/Phraseanet/compare/4.1.9...4.1.10
@@ -206,7 +270,7 @@ ___
206270
207271
- No change
208272
209-
## What's Changed
273+
### What's Changed
210274
* PHRAS-4083_searchraw-limit-offset-to-result by @jygaulier in https://github.com/alchemy-fr/Phraseanet/pull/4528
211275
* PHRAS-4082: Github action - Check the push image method by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4530
212276
* PHRAS-4086_pdftotext-exception by @jygaulier in https://github.com/alchemy-fr/Phraseanet/pull/4532
@@ -242,7 +306,7 @@ ___
242306
- Build of Phraseanet image has been updated with a "Phraseanet base image" available on dockerhub
243307
244308
245-
## What's Changed
309+
### What's Changed
246310
* PHRAS-4058 Admin - workermanager default filter since 3 days by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4507
247311
* PHRAS-4064 Fix worker plugin install as app by @moctardiouf in https://github.com/alchemy-fr/Phraseanet/pull/4508
248312
* PHRAS-4042 Fix language in webvtt field uploaded to expose by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4510
@@ -282,7 +346,7 @@ ___
282346
283347
- Redis native session support
284348
285-
## What's Changed
349+
### What's Changed
286350
* PHRAS-4041:Prod - matomo - Field display - improve rendering of Matomomediametrics by @aynsix in https://github.com/alchemy-fr/Phraseanet/pull/4497
287351
* PHRAS-3416 Local for worker jobs by @nmaillat in https://github.com/alchemy-fr/Phraseanet/pull/4499
288352
* PHRAS-4056 Change imagemagick version and config file path by @moctardiouf in https://github.com/alchemy-fr/Phraseanet/pull/4500

docker-compose.datastores.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ services:
1515
- MYSQL_QUERY_CACHE_LIMIT
1616
- MYSQL_QUERY_CACHE_SIZE
1717
- MYSQL_KEY_BUFFER_SIZE
18+
- MARIADB_AUTO_UPGRADE
1819
volumes:
1920
- ${PHRASEANET_DB_DIR}:/var/lib/mysql
2021
networks:

docker/db/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
FROM mariadb:10.4.5
1+
FROM mariadb:10.11.11
22

33
RUN apt-get update && \
44
apt-get install -y \

0 commit comments

Comments
 (0)