Skip to content

Commit d8027ca

Browse files
committed
Fixing Tugboat installation.
1 parent 65aaadd commit d8027ca

File tree

2 files changed

+19
-10
lines changed

2 files changed

+19
-10
lines changed

.tugboat/config.yml

Lines changed: 17 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,17 @@
11
services:
22
php:
3-
image: tugboatqa/php:7.2-apache
3+
image: tugboatqa/php:8.3-apache-bullseye
44
default: true
5-
depends: mariadb
5+
depends: mysql
66
commands:
77
init:
8-
# Install PHP 'zip' extension to allow installing Backdrop modules.
9-
- docker-php-ext-install zip
8+
# Ensure JPG support is enabled.
9+
# See https://github.com/docker-library/php/issues/912#issuecomment-559918036
10+
- docker-php-ext-configure gd --with-jpeg
11+
# Install zip, igbinary, memcache, and opcache PHP extensions support.
12+
- apt update
13+
- apt install libzip-dev
14+
- docker-php-ext-install zip opcache gd > /dev/null
1015
# Enable Apache 'rewrite' module for clean URLs.
1116
- a2enmod rewrite
1217
# Link the document root to the expected path.
@@ -36,12 +41,16 @@ services:
3641
- cd $TUGBOAT_ROOT/www && $TUGBOAT_ROOT/.tugboat/reset-password.sh
3742
# Post a comment in the PR.
3843
- cd $TUGBOAT_ROOT/.tugboat && ./post-comment.sh
39-
mariadb:
40-
image: tugboatqa/mariadb:latest
44+
mysql:
45+
# Use the latest available 8.x version of MySQL
46+
image: tugboatqa/mysql:8
4147
commands:
4248
init:
43-
# Configure database for UTF-8: https://api.backdropcms.org/database-configuration#utf8mb4
44-
- echo "[mysqld]\ninnodb_large_prefix=true\ninnodb_file_format=barracuda\ninnodb_file_per_table=true" >> /etc/mysql/conf.d/utf8mb.conf
49+
# Avoids "MYSQL has gone away" issues.
50+
# See: https://docs.tugboat.qa/troubleshooting/fix-problem-x/#mysql-server-has-gone-away
51+
- mysql -e "SET GLOBAL max_allowed_packet=536870912;"
52+
- echo "max_allowed_packet=536870912" >> /etc/mysql/conf.d/tugboat.cnf
53+
4554
# Download a copy of the latest database.
4655
- wget --http-user=$SANITIZE_USER --http-password=$SANITIZE_PASS -c https://sanitize.backdropcms.org/forum.backdropcms.org/sanitized/forum-latest-sanitized.sql.gz
4756
- gunzip forum-latest-sanitized.sql.gz

.tugboat/settings.local.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
11
<?php
22
// Database.
3-
$database = 'mysql://tugboat:tugboat@mariadb/tugboat';
3+
$database = 'mysql://tugboat:tugboat@mysql/tugboat';
44
$database_charset = 'utf8mb4';
55

66
// Config.
77
$config_directories['active'] = '../config/live-active';
88
$config_directories['staging'] = '../config/staging';
99

1010
// Trusted hosts.
11-
$settings['trusted_host_patterns'] = array('^.+\.tugboat\.qa$');
11+
$settings['trusted_host_patterns'] = array('^.+\.tugboatqa\.com$');
1212

1313
// Miscellaneous.

0 commit comments

Comments
 (0)