Sync extension versions with MW, and trim abra.sh

This commit is contained in:
3wc 2023-09-09 14:51:45 +02:00
parent 6d53472222
commit 9e29ebf8d0
2 changed files with 7 additions and 45 deletions

38
abra.sh
View File

@ -5,41 +5,3 @@ export COMPOSER_LOCAL_CONF_VERSION=v5
export PHP_INI_VERSION=v4
export SAML_ENTRYPOINT_CONF_VERSION=v3
abra_backup_app() {
_abra_backup_dir "app:/var/www/html/images"
}
abra_backup_db() {
_abra_backup_mysql "db" "mediawiki"
}
abra_backup() {
abra_backup_app && abra_backup_db
}
abra_restore_app() {
# shellcheck disable=SC2034
{
abra__src_="-"
abra__dst_="app:/var/www/html/"
}
zcat "$@" | sub_app_cp
success "Restored 'app'"
}
abra_restore_db() {
# 3wc: unlike abra_backup_db, we can assume abra__service_ will be 'db' if we
# got this far..
# shellcheck disable=SC2034
abra___no_tty="true"
DB_ROOT_PASSWORD="$(sub_app_run cat /run/secrets/db_root_password)"
zcat "$@" | sub_app_run mysql -u root -p"$DB_ROOT_PASSWORD" wordpress
success "Restored 'db'"
}

View File

@ -48,14 +48,14 @@ init_db() {
init_extensions() {
if [ ! -d /var/www/html/extensions/PluggableAuth ]; then
git clone --depth 1 -b REL1_39 \
git clone --depth 1 -b REL1_40 \
https://gerrit.wikimedia.org/r/p/mediawiki/extensions/PluggableAuth \
/var/www/html/extensions/PluggableAuth
fi
if [ -n "${SAML_ENABLED-}" ]; then
if [ ! -d /var/www/html/extensions/SimpleSAMLphp ]; then
git clone --depth 1 -b REL1_39 \
git clone --depth 1 -b REL1_40 \
https://gerrit.wikimedia.org/r/p/mediawiki/extensions/SimpleSAMLphp \
/var/www/html/extensions/SimpleSAMLphp
fi
@ -63,7 +63,7 @@ init_extensions() {
if [ -n "${OPENID_ENABLED-}" ]; then
if [ ! -d /var/www/html/extensions/OpenIDConnect ]; then
git clone --depth 1 -b REL1_39 \
git clone --depth 1 -b REL1_40 \
https://gerrit.wikimedia.org/r/mediawiki/extensions/OpenIDConnect \
/var/www/html/extensions/OpenIDConnect
fi
@ -71,7 +71,7 @@ init_extensions() {
if [ -n "${MOBILEFRONTEND_ENABLED-}" ]; then
if [ ! -d /var/www/html/extensions/MobileFrontend ]; then
git clone --depth 1 -b REL1_39 \
git clone --depth 1 -b REL1_40 \
https://github.com/wikimedia/mediawiki-extensions-MobileFrontend.git \
/var/www/html/extensions/MobileFrontend
fi
@ -79,7 +79,7 @@ init_extensions() {
if [ -n "${MSU_ENABLED-}" ]; then
if [ ! -d /var/www/html/extensions/MsUpload ]; then
git clone --depth 1 -b REL1_39 \
git clone --depth 1 -b REL1_40 \
https://gerrit.wikimedia.org/r/mediawiki/extensions/MsUpload \
/var/www/html/extensions/MsUpload
fi
@ -87,7 +87,7 @@ init_extensions() {
if [ -n "${PAGEFORMS_ENABLED-}" ]; then
if [ ! -d /var/www/html/extensions/PageForms ]; then
git clone --depth 1 -b REL1_39 \
git clone --depth 1 -b REL1_40 \
https://gerrit.wikimedia.org/r/mediawiki/extensions/PageForms \
/var/www/html/extensions/PageForms
fi
@ -95,7 +95,7 @@ init_extensions() {
if [ -n "${PAGESCHEMAS_ENABLED-}" ]; then
if [ ! -d /var/www/html/extensions/PageSchemas ]; then
git clone --depth 1 -b REL1_39 \
git clone --depth 1 -b REL1_40 \
https://gerrit.wikimedia.org/r/mediawiki/extensions/PageSchemas \
/var/www/html/extensions/PageSchemas
fi