Framadate : migrer vers MariaDB #5

Closed
opened 2022-11-07 17:26:24 +00:00 by gitouche · 1 comment
Owner

Ceci est un report de l'issue https://framagit.org/garbaye/services-garbaye/-/issues/5

Mentionné comme compatible https://framagit.org/framasoft/framadate/framadate/-/blob/v1.1.x/README.md

Permettra de faire sauter la contrainte x86_64 sur la CI https://framagit.org/garbaye/services-garbaye/-/blob/main/podman-framadate/.gitlab-ci.yml#L22

MariaDB ayant des images arm64, contrairement à MySQL

Ceci est un report de l'issue https://framagit.org/garbaye/services-garbaye/-/issues/5 Mentionné comme compatible https://framagit.org/framasoft/framadate/framadate/-/blob/v1.1.x/README.md Permettra de faire sauter la contrainte x86_64 sur la CI https://framagit.org/garbaye/services-garbaye/-/blob/main/podman-framadate/.gitlab-ci.yml#L22 MariaDB ayant des images arm64, contrairement à MySQL
gitouche added the
type:amélioration
label 2022-11-07 20:29:13 +00:00
gitouche added the
priorité:basse
label 2022-11-07 20:37:20 +00:00
gitouche self-assigned this 2023-02-18 22:12:24 +00:00
Author
Owner

C'est fait . Quelque notes :

# dump de la base
podman exec -it -e MYSQL_PWD=${GARBAYE_FRAMADATE_MYSQL_PASSWORD} framadate-db mysqldump --skip-set-charset --default-character-set=latin1 -uframadate framadate > /tmp/framadump
# Arrêt du service
./40_stop.sh
# Éditer /tmp/framadump pour remplacer les utf8 par latin1.
# emacs...
# Archiver le volume au cas où..
podman volume export podman-framadate_framadate-db > ~/podman-framadate_framadate-db.tar
# Destruction et réinstallation
./80_destroy.sh 
podman volume rm podman-framadate_framadate-db 
./05_freshinstall.sh 
./20_enable.sh 
./30_start.sh 
# Ré-import de la base
podman exec -i -e MYSQL_PWD=${GARBAYE_FRAMADATE_MYSQL_PASSWORD} framadate-db mysql -uframadate framadate < /tmp/framadump
# Migration des tables vers UTF8
podman exec -it -e MYSQL_PWD=${GARBAYE_FRAMADATE_MYSQL_PASSWORD} framadate-db mysql -uframadate framadate
ALTER TABLE fd_comment CONVERT TO CHARACTER SET utf8;
ALTER TABLE fd_framadate_migration CONVERT TO CHARACTER SET utf8;
ALTER TABLE fd_poll CONVERT TO CHARACTER SET utf8;
ALTER TABLE fd_slot CONVERT TO CHARACTER SET utf8;
ALTER TABLE fd_vote CONVERT TO CHARACTER SET utf8;
# si tout ok, nettoyer... ~/podman-framadate_framadate-db.tar /tmp/framadump
C'est fait . Quelque notes : ``` # dump de la base podman exec -it -e MYSQL_PWD=${GARBAYE_FRAMADATE_MYSQL_PASSWORD} framadate-db mysqldump --skip-set-charset --default-character-set=latin1 -uframadate framadate > /tmp/framadump # Arrêt du service ./40_stop.sh # Éditer /tmp/framadump pour remplacer les utf8 par latin1. # emacs... # Archiver le volume au cas où.. podman volume export podman-framadate_framadate-db > ~/podman-framadate_framadate-db.tar # Destruction et réinstallation ./80_destroy.sh podman volume rm podman-framadate_framadate-db ./05_freshinstall.sh ./20_enable.sh ./30_start.sh # Ré-import de la base podman exec -i -e MYSQL_PWD=${GARBAYE_FRAMADATE_MYSQL_PASSWORD} framadate-db mysql -uframadate framadate < /tmp/framadump # Migration des tables vers UTF8 podman exec -it -e MYSQL_PWD=${GARBAYE_FRAMADATE_MYSQL_PASSWORD} framadate-db mysql -uframadate framadate ALTER TABLE fd_comment CONVERT TO CHARACTER SET utf8; ALTER TABLE fd_framadate_migration CONVERT TO CHARACTER SET utf8; ALTER TABLE fd_poll CONVERT TO CHARACTER SET utf8; ALTER TABLE fd_slot CONVERT TO CHARACTER SET utf8; ALTER TABLE fd_vote CONVERT TO CHARACTER SET utf8; # si tout ok, nettoyer... ~/podman-framadate_framadate-db.tar /tmp/framadump ```
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: Garbaye/services-garbaye#5
No description provided.